Home

Awesome

react-backbone

Give Backbone awareness to your React components and so much more.

This project indludes/depends on the following other projects

Common Examples

    React.createClass({
      mixins: ['modelChangeAware'],

      render: function() {
        // will be called any time this.props.model is changed
      }
    });
    React.createClass({
      mixins: ['modelXHRAware'],

      render: function() {
        // this.state.loading will be truthy during any XHR activity initiated by this.props.model
      }
    });
    React.createClass({
      mixins: ['modelEvents'],

      events: {
        'model:foo': 'onFoo',
        '*throttle(300)->model:foo': 'onThrottledFoo'
        ''
      },

      onFoo: function() {
        will be executed when this.props.model triggers the "foo" event
      },

      onThrottledFoo: function() {
        will be executed and throttled (300ms) when this.props.model triggers the "foo" event
      },
    });

Docs

View the installation and API docs

Tutorials