Created
September 24, 2013 19:18
-
-
Save petehunt/6689857 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
/** @jsx React.DOM */ | |
var Hello = React.createClass({ | |
mixins: [LinkedStateMixin], | |
getInitialState: function() { | |
return {name: 'phunt'}; | |
}, | |
render: function() { | |
return ( | |
<div> | |
<input type="text" valueLink={this.linkState('name')} /> | |
{this.state.name} | |
</div> | |
); | |
} | |
}); | |
React.renderComponent(<Hello />, document.body); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment