Skip to content

Instantly share code, notes, and snippets.

@cjohansen
Last active September 15, 2016 09:26
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 cjohansen/040ce027b61923ce3d63 to your computer and use it in GitHub Desktop.
Save cjohansen/040ce027b61923ce3d63 to your computer and use it in GitHub Desktop.
function appUI(actions) {
return React.createClass({
render: function () {
return React.DOM.h1({onClick: actions.doit}, 'LOL');
}
});
}
var data = {}
function render() {
React.render(App(data), elem);
}
var App = AppUI({
login: function () {
data.user = {name: 'Bob'};
}
});
render();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment