Does new React Context API trigger re-renders?
I have been trying to understand the new React Context API and was playing with it. I just wanted to check a simple case - what all re-renders when data to a Provider is updated. Check this small example on Codesandbox So, in my example, I have an App component - that has state something like this -- this.state = { number - A random number text - A static text } I create a new React Context from here containing number and text from state and pass the values to two Consumers Number and Text . So my assumption is if the random number updates, it will change the context and both the components