react-native Could not find "store" in either the context or props


1.參考 https://stackoverflow.com/questions/35420989/could-not-find-store-in-either-the-context-or-props

2.在所有需要綁定Redux的文件中使用connect

容器組件使用 connect() 方法連接 Redux

我的是在index.js中,import store from './src/redux/store';

<Provider store={store}>

</Provider>


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM