Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR upgrades the
react
andreact-dom
development dependencies, and specifies that we now support React 17 in thepeerDependencies
.React 17 changes the timing of when effects are cleaned up. This caused one of our tests to break, since it was synchronsly asserting that
element.destroy
was called when an Element component was unmounted. To fix the test, I needed to upgrade our@testing-library/react
dependency to at least 10.4.7, which ensures that effects are flushed synchronously whenunmount
is called in a test. I also upgraded a few related deps, just to keep us up to date.A different test failed due to the additional Concurrent Mode changes in React 17. As before, Concurrent Mode is proving to be too unstable to reliably support without breaking changes, so I've disabled this test.
All tests are now passing, and I did a quick smoke test in a sample React 16 and React 17 app.