2017-01-06 61 views
1

我是新來對本機進行反應的。 我已經正確安裝了項目並能夠在模擬器中運行它。 現在我想爲我的項目使用react-redux。當我運行時npm install --save react-redux我收到以下錯誤。通過react-redux實現react-native時出錯

+-- [email protected] 
`-- UNMET PEER DEPENDENCY [email protected]^2.0.0 || ^3.0.0 

npm WARN [email protected] requires a peer of [email protected]^2.0.0 || ^3.0.0 but none was installed. 

enter image description here

我使用的Windows + Android模擬器,有這麼多的解決方案,但所有基於IOS。 我也嘗試手動。

我的package.json文件:

"dependencies": { 
    "react": "15.4.1", 
    "react-native": "0.40.0", 
    "react-redux": "^5.0.1", 
    "redux": "^3.5.2" 
    }, 

回答

1

意識到這不是錯誤,就是缺少相關模塊。運行npm install --save redux


做工精細它也需要兩個依賴模塊:

npm install --save redux-logger 
npm install --save redux-thunk 
相關問題