Update react-redux to the latest version 🚀 #1368
Closed
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.
The dependency react-redux was updated from
5.1.1
to7.1.2
.This version is not covered by your current version range.
If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.
Publisher: acemarke
License: MIT
Release Notes for v7.1.2
This releases fixes a subtle timing bug with
connect
anduseSelector
in React Native environments, and adds the ability to pass through non-Redux-store values as astore
prop.Changes
Fixed Store Subscriptions in React Native
Our current implementation requires cascading updates down through connected components. This is primarily done during React's "commit phase" via the
useLayoutEffect
hook. Unfortunately, React warns whenuseLayoutEffect
is called in SSR environments, so we try to feature-detect that and fall back touseEffect
just to avoid that warning.Unfortunately, a tweak to the feature detection conditions during the pre-7.1.0 work caused the check to accidentally fail in React Native environments. This meant that
useEffect
was actually being used all the time, and this led to occasional timing bugs such as #1313 and #1437 . This affected the previous v7.1.x releases.We've fixed that issue, and added additional test cases to ensure that our code works correctly under React Native.
See #1444 for more details on the feature detection and the fix.
Passing Through Non-Store Values
connect
has always accepted passing a Redux store directly to connected components as a prop namedstore
(with the exception of v6). As a result, thestore
prop has effectively been treated as a "reserved" prop, in much the same way thatkey
andref
are "reserved" prop names handled by React.Some users may be using the word "store" to describe their domain data, and have asked to allow variables that aren't a Redux store through the
store
prop to the component (#1393). We've finally been able to implement that capability.Changelog
store
prop (@markerikson - #1447)latestStoreState
field (@Hypnosphi - #1426)v7.1.1...v7.1.2
Commits
The new version differs by 161 commits ahead by 161, behind by 3.
5f495b2
7.1.2
2677705
Pass non-Redux-store values through the
store
prop (#1447)b832f83
Fix RN batching and effect behavior (#1444)
b5034a6
Bump mixin-deep from 1.3.1 to 1.3.2 in /website (#1442)
4be8b3f
[ImgBot] Optimize images (#1434)
2eac861
fix spelling in error message (#1427)
6725400
Remove unused
latestStoreState
field (#1426)388d9e4
Mark the react renderers as optional peer deps.
2297944
Add DEV Community link to Community Resources (#1423)
69d62e4
Use the same condition for checking if SSR in useSelector.js as in connectAdvanced.js (#1419)
31c998a
Docs: Fixes code example for API connect mapState (#1415)
4bc231f
Revert "Docs: Fix Code Example for API
connect()
" (#1414)d9c49fa
Docs: Fixes code example for API connect (#1413)
063c2ed
Troubleshooting: add useLayoutEffect + Jest info (#1411)
6c873c7
Add reference post in hooks description (#1395)
There are 161 commits in total.
See the full diff
FAQ and help
There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.
Your Greenkeeper bot 🌴