Created
June 7, 2012 13:49
-
-
Save markevans/2888879 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(){ | |
// SAME EXAMPLE USING PLUGINS | |
}) |
show me how to do it with plugins. show me! show me the money!!!!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
on button click, the view calls the "selected" method on its delegate.