Last active
September 25, 2015 13:59
-
-
Save BrunoCaimar/87d88e06758d5b0d644c to your computer and use it in GitHub Desktop.
Dojo - Topic / Events / AMD
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
-- Topic - Pub/Sub infra | |
---- topic.subscribe / topic.publish | |
-- Dojo/On - Events related to objects or DOM | |
---- dojo.on(target, event, function2handleIt) | |
---- dojo.on.emit(target, event, params) | |
---- on.once(t, e, f) - Run just once | |
AMD | |
"my/otherModule" is one directory up, so we use "../" | |
"my/widget/InfoBox" is in the same directory, so we use "./" | |
lang | |
- extend/mixin to 'monkey patching' | |
lang.hitch | |
- provides context to an event (like put actual 'this' in a specified event context) | |
lang.partial | |
- fixed params to functions like callbacks | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment