我无法安装组件,因为我收到此错误:
npm install react-native-side-menu
Rdemo@0.0.1 /home/mss/Desktop/cakenew25_aug/MagentoLatest/Rdemo
+-- UNMET PEER DEPENDENCY react@16.0.0-alpha.6
`-- react-native-side-menu@0.20.1
npm WARN react-native-selectbox@0.1.2 requires a peer of react@>15.0 but none was installed.
npm WARN react-static-container@1.0.1 requires a peer of react@^0.13.0 || ^0.14.0 || ^15.0.0 but none was installed.
我正在尝试在我的本机演示中实现侧面菜单。我是这个平台和自学者的新手。 我在本演示中使用react-native-router-flux 架构。
我从下面的链接获得了侧面菜单实现的示例: -
我尝试按照命令排除此错误,但没有成功: -
npm install npm@latest -g
npm prune
npm install --save react@16.0.0-alpha.6
反应原生版本信息: -
react-native-cli: 2.0.1
react-native: 0.44.0
这是我的Package.json: -
{
"name": "Rdemo",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"test": "jest"
},
"dependencies": {
"react": "^16.0.0-alpha.6",
"react-native": "0.44.0",
"react-native-check-box": "^1.0.4",
"react-native-drawer": "^2.3.0",
"react-native-easy-toast": "^1.0.6",
"react-native-flexi-radio-button": "^0.2.0",
"react-native-router-flux": "^3.38.0",
"react-native-selectbox": "^0.1.2",
"react-native-vector-icons": "^4.1.1",
"react-native-web-service-handler": "^1.0.2"
},
"devDependencies": {
"babel-jest": "20.0.3",
"babel-preset-react-native": "1.9.2",
"jest": "20.0.3",
"react-test-renderer": "16.0.0-alpha.6"
},
"jest": {
"preset": "react-native"
}
}
npm详细信息: -
npm list --depth=0
Rdemo@0.0.1 /home/mss/Desktop/cakenew25_aug/MagentoLatest/Rdemo
+-- babel-jest@20.0.3
+-- babel-preset-react-native@1.9.2
+-- jest@20.0.3
+-- UNMET PEER DEPENDENCY react@16.0.0-alpha.6
+-- react-native@0.44.0
+-- react-native-check-box@1.0.4
+-- react-native-drawer@2.3.0
+-- react-native-easy-toast@1.0.6
+-- react-native-flexi-radio-button@0.2.0
+-- react-native-router-flux@3.39.2
+-- react-native-selectbox@0.1.2
+-- react-native-vector-icons@4.2.0
+-- react-native-web-service-handler@1.0.2
`-- react-test-renderer@16.0.0-alpha.6
npm ERR! peer dep missing: react@>15.0, required by react-native-selectbox@0.1.2
npm ERR! peer dep missing: react@^0.13.0 || ^0.14.0 || ^15.0.0, required by react-static-container@1.0.1
Node version :- v6.9.1
npm version :- v3.10.8
以下是我的错误的屏幕截图: -
任何帮助, 感谢