Skip to content

Instantly share code, notes, and snippets.

@Takazudo
Created November 27, 2012 09:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Takazudo/4153361 to your computer and use it in GitHub Desktop.
Save Takazudo/4153361 to your computer and use it in GitHub Desktop.
lazyEventModuleWithBackbone
class Module
_.extend Module::, Backbone.Events
class App extends Module
app = new App
app.on 'hoge', ->
console.log 'hoge done!'
app.trigger 'hoge' # hoge done!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment