-
-
Save sjltaylor/2896379 to your computer and use it in GitHub Desktop.
Example use of a view, using the class stuff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
define(['view'], function(View){ | |
return View.sub('ItemView', function(){ | |
this.domEvent('click', 'button', 'selected') | |
}) | |
}) | |
/////////////////////////////////////////////////////// | |
define([], function(){ | |
return Type('ItemView') // name is optional | |
.use(View) // this defines a static 'domEvent' function which I use below | |
.domEvent('click', 'button', 'selected') | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment