Skip to content

Instantly share code, notes, and snippets.

@velotiotech
Created June 26, 2020 11:48
Embed
What would you like to do?
increaseCount = () => {
this.setState({ count: this.state.count + 1 });
};
render() {
return (
<div className="App">
<button onClick={this.increaseCount}>
COUNT ({this.state.count})
</button>
</div>
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment