SlideShare uses cookies to improve functionality and performance, and to provide you with relevant advertising. If you continue browsing the site, you agree to the use of cookies on this website. See our User Agreement and Privacy Policy.
SlideShare uses cookies to improve functionality and performance, and to provide you with relevant advertising. If you continue browsing the site, you agree to the use of cookies on this website. See our Privacy Policy and User Agreement for details.
Successfully reported this slideshow.
Activate your 14 day free trial to unlock unlimited reading.
We are at an intersection of 2 paths. One is about the evolution of how we share code between React components, and the second is about how we share data between them.
In this talk, we will explore how we can leverage the power of hooks in global state management, what are the benefits and drawbacks to using Context API, and what alternatives do we have.
We are at an intersection of 2 paths. One is about the evolution of how we share code between React components, and the second is about how we share data between them.
In this talk, we will explore how we can leverage the power of hooks in global state management, what are the benefits and drawbacks to using Context API, and what alternatives do we have.
9.
Render Props
const App = () => (
<div>
<Mouse render={({ x, y }) => (
// The render prop gives us the state we need
// to render whatever we want here.
<h1>The mouse position is ({x}, {y})</h1>
)}/>
</div>
);
10.
Render Props
const App = () => (
<div>
<Mouse render={({ x, y }) => (
// The render prop gives us the state we need
// to render whatever we want here.
<h1>The mouse position is ({x}, {y})</h1>
)}/>
</div>
);