Last active
September 15, 2016 09:26
-
-
Save cjohansen/040ce027b61923ce3d63 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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