Skip to content

Instantly share code, notes, and snippets.

@JasonGiedymin
Created July 8, 2011 03:10
Show Gist options
  • Save JasonGiedymin/1071047 to your computer and use it in GitHub Desktop.
Save JasonGiedymin/1071047 to your computer and use it in GitHub Desktop.
Extending Backbone.Model in CoffeeScript
Backbone = require 'backbone'
class Foo extends Backbone.Model
set: -> super
foo = new Foo
foo.set x: 'x'
console.log foo.get 'x' # x
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment