Skip to content

Instantly share code, notes, and snippets.

@blixt
Created July 18, 2014 00:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save blixt/5c24f8ac1772c6f76129 to your computer and use it in GitHub Desktop.
Save blixt/5c24f8ac1772c6f76129 to your computer and use it in GitHub Desktop.
// Set up the feed node.
var feedNode = <feed onShowNewStories={store.dequeue.bind(store)} />;
React.renderComponent(feedNode, document.getElementById('react'));
// Keep track of the state of the feed service.
store.on('statechange', function() {
feedNode.setState({storeState: store.state});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment