Created
February 17, 2011 10:50
-
-
Save blambeau/831484 to your computer and use it in GitHub Desktop.
An example of syntax
This file contains hidden or 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
class Hello extends Brick | |
constructor: -> | |
# Cell for the current view | |
@current = new Cell | |
# View handler for #content | |
@content = new View | |
selector: | |
'#content' | |
url: | |
this.current | |
autorefresh: | |
this.current.changed | |
wInit: -> | |
this.current.set('hello1.html') | |
$(document).ready -> | |
this.HelloApp = new Hello | |
this.HelloApp.wRun() | |
# | |
# On the view side: | |
# | |
# <a onclick="HelloApp.current.set('hello1.html')">Hello1</a> | |
# <a onclick="HelloApp.current.set('hello2.html')">Hello2</a> | |
# |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment