-
Notifications
You must be signed in to change notification settings - Fork 49.9k
Description
Do you want to request a feature or report a bug?
bug or unexpected behavior
What is the current behavior?
In version react-dom@16.6.1 I used Context.Consumer in renderToStaticMarkup and it works fine if a call it, but in react-dom@16.6.3 Context.Consumer lose Context.Provider. To be precise Consumer loses only new values passed to Provider, default values work fine in all cases.
Example below:
with react-dom@16.6.1 - https://codesandbox.io/s/0movl04pyw
with react-dom@16.6.3 - https://codesandbox.io/s/6j39m60j9n
What is the expected behavior?
Context.Consumer don't lose a context passed with Context.Provider.
Maybe the example is wrong and there is another way to render Context.Consumer's components into a string?
Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?
In react-dom@16.6.1 - works fine
In react-dom@16.6.3 - context losed