Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: b8dd28afae
Fetching contributors…

Cannot retrieve contributors at this time

31 lines (28 sloc) 1.145 kb
<div id="{{mojit_view_id}}">
<li>Binders are the sole access point to controllers and the rest of Mojito in the client.</li>
<li>Binders have access to autoloads and <a href="">MojitProxy</a>, which wraps the controller and configuration.</li>
<li>Binders provide a messaging interface for cross-mojit communication via <code>subscribe</code> and <code>listen</code>.</li>
YUI.add('FooBinder', function(Y, NAME)
Y.namespace('mojito.binders')[NAME] =
init: function(mojitProxy) {
this.proxy = mojitProxy;
bind: function(node) {
// set up some listeners
// node is the Y.Node containing id="&#123;{mojit_view_id}}" in the view
onRefreshView: function(node) {
// do something after refreshView
}, '0.0.1', {requires: ['mojito-client']});
<p><a href="/src/mojits/Weather/binders/index.js">Example binder</a></p>
Jump to Line
Something went wrong with that request. Please try again.