paint-brush
You might not need React Contextby@cmichel
389 reads
389 reads

You might not need React Context

by Christoph Michel6mApril 23rd, 2018
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

React 16.3 finally made the <a href="https://reactjs.org/docs/context.html" target="_blank">Context API</a> stable. Since then, many developers started using it to solve the “prop-drilling” problem — the issue where you need to pass a <code class="markup--code markup--p-code">prop</code> down the component tree along components not making use of it in order to access that <code class="markup--code markup--p-code">prop</code> in a component being rendered <em>deep down</em> the tree. The <a href="https://hackernoon.com/tagged/react" target="_blank">React</a> documentation states the intent of the Context API as follows:

Company Mentioned

Mention Thumbnail
featured image - You might not need React Context
Christoph Michel HackerNoon profile picture
Christoph Michel

Christoph Michel

@cmichel

L O A D I N G
. . . comments & more!

About Author

Christoph Michel HackerNoon profile picture
Christoph Michel@cmichel

TOPICS

THIS ARTICLE WAS FEATURED IN...

Permanent on Arweave
Read on Terminal Reader
Read this story in a terminal
 Terminal
Read this story w/o Javascript
Read this story w/o Javascript
 Lite
Freesion