Created
April 15, 2019 13:23
-
-
Save benkissi/28d63761352338acb5ad832a8a48c0bf to your computer and use it in GitHub Desktop.
Context blog
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
render() { | |
return ( | |
<AppContext.Provider | |
value={{ | |
todos: this.state.todos, | |
addTodo: this.addTodo, | |
completed: this.completed | |
}} | |
> | |
{this.props.children} | |
</AppContext.Provider> | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment