I initiated a new project React Native Expo with expo init MyProject.
My dependencies:
"dependencies": {
"@expo/vector-icons": "latest",
"emoji-utils": "latest",
"expo": "^32.0.0",
"moment": "^2.24.0",
"react": "16.5.0",
"react-native": "https://github.com/expo/react-native/archive/sdk-32.0.0.tar.gz",
"react-native-gifted-chat": "^0.7.3",
"react-native-keyboard-spacer": "^0.4.1",
"react-native-nav": "^2.0.2",
"react-navigation": "^3.7.1",
"react-redux": "^7.0.2",
"redux": "^4.0.1",
"redux-thunk": "^2.3.0"
},
"devDependencies": {
"babel-preset-expo": "^5.0.0"
},
When I make export default connect(mapStateToProps)(Chat) on my component I've the error _react.default.memo is not a function.
On the other hand, if I pass the version of react-redux to 6.0.0 I do not have this error anymore...
This is a bug tracker, not a support system. For usage questions, please use Stack Overflow or Reactiflux where there are a lot more people ready to help you out - you'll probably get a better answer faster. Thanks!
Ah... that said, React-Redux v7 requires a minimum React version of 16.8.4. Please upgrade your React Native and React versions accordingly.
@JuAlexandre I had the same issue.
Didn't realize that React Native v0.59.8 depends on React 16.5.0.
It seems that from react-redux v7 React version 16.8.4 or higher is needed, because it internally uses React.memo().