|
@ -20,7 +20,7 @@ var LikeButton = React.createClass({ |
|
|
this.setState({liked: !this.state.liked}); |
|
|
this.setState({liked: !this.state.liked}); |
|
|
}, |
|
|
}, |
|
|
render: function() { |
|
|
render: function() { |
|
|
var text = this.state.liked ? 'like' : 'haven\'t liked'; |
|
|
var text = this.state.liked ? 'liked' : 'haven\'t liked'; |
|
|
return ( |
|
|
return ( |
|
|
<p onClick={this.handleClick}> |
|
|
<p onClick={this.handleClick}> |
|
|
You {text} this. Click to toggle. |
|
|
You {text} this. Click to toggle. |
|
|