Category Archives: Javascript

Javascript Templating and Frameworks

Ongoing and incomplete review of javascript templating systems and frameworks.

Templating

Unobtrusive (HTML + JSON)

‘Standard’ Templating Browser

Listings

Testing

  • nodeunit
  • qunit
  • jasmine
  • sinon.js (mocking) – integrates with qunit well

Frameworks

Client-side

  • backbone – used quite a bit
  • knockout
  • (big) sproutcore

Node

  • express
    • tags: nodejs
  • backbone now supported pretty well

Messaging and Job Queues

HTML5

ORMs

  • For mongo: http://mongoosejs.com/
  • Backbone sort of includes one (though relationships are poorly handled at the moment)

Where Does My Money Go? Spending Explorer using Protovis and jQuery

Over the last couple of months I’ve been playing around with Protovis in my spare time to create an interactive pure javascript Government Spending Explorer for Where Does My Money Go? (datastore api):

Warning: won’t work in IE (atm due to lack of svg support) and works best (i.e. fastest) in Chrome!

I’d be interested in any feedback and any suggestions for experience with protovis or any other javascript libraries (I’ve also used flot and thejit a bit). In particular one thing a bit lacking currently in protovis is any animation (something that’s goodin thejit …).

Features:

  • True ‘explorer': you can choose any set of breakdown ‘keys’ to visualize
  • Primary ‘financial bubbles’ view with interactive navigation into bubbles
    • Support for arbitrary depth of data ‘tree’ so you can keep navigating down (though currently limited by user interface to select at most 3 levels)
  • Multiple other visualizations including treemap, sunburst, dendrogram and ‘icicle’
  • Time support
  • View the source data in table or as json

I’m sure there’s tons to improve especially on the usability (e.g. should default labels have amounts in them?) so if you take a look please let me know any feedback.

Some specific limitations:

  • Does not work in IE — but hope to fix this using svg.js soon
  • Colours and general ‘look’ could be improved — help wanted!
  • Occasional bugs e.g. weird redraws — if you find one please let me know