Skip to content

Instantly share code, notes, and snippets.

@LBRapid
Last active August 29, 2015 14:00
Show Gist options
  • Select an option

  • Save LBRapid/11148483 to your computer and use it in GitHub Desktop.

Select an option

Save LBRapid/11148483 to your computer and use it in GitHub Desktop.
Render a react component from a Backbone router
Backbone.Router.extend({
routes: 'users/index',
index: function() {
var component, users;
users = Users.fetch();
component = UsersIndex({
model: users
});
return React.renderComponent(component, document.getElementById('container'));
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment