Created
May 13, 2015 17:46
-
-
Save cray0000/53774f2bcb13b429f8df to your computer and use it in GitHub Desktop.
Derby.js Component primitives
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
module.exports = class ComponentBase | |
init: -> | |
@root = @page.root | |
@model.ref 'root', @root.model |
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
module.exports = class ComponentPage | |
init: -> | |
@page.root = this | |
# And some way to have _page to be the local model of the "page component" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment