3 ms·
Awesome! Any plans to integrate this with coffeescript? I see someone's already taken a stab at it: http://gist.github.com/625893 http://gist.github.com/625893
by boothead 16y ago
Awesome! Any plans to integrate this with coffeescript? I see someone's already taken a stab at it:
http://gist.github.com/625893 http://gist.github.com/625893
- jashkenas 16y agoIt's just JavaScript, so they should work together fine: Todo = Backbone.Model.extend done: -> @get("status") is "done" toggle: -> @set status: if @done() then "active" else "done" Doing a quick Backbone.coffee version would be fun though, hmm...
- boothead 16y agoTBH I was a little surprised that you didn't write this in coffee in the first place :-) Isn't this the kind of thing that coffee would be aimed at?
- jashkenas 16y agoYes, and the CoffeeScript version would probably perform marginally faster. But pragmatism comes first. Because this is a part of a grant-funded project, it needs to be available and accessible to the widest possible audience -- and that means JavaScript.