2016-05-26 3 views
2

Я пытаюсь установить материал-интерфейс на новый React-Native проект, который работает реагировать родной: 0.26.2 & реагируют: «15.0.2 . , когда я установил материал-интерфейс НОГО пакет я получил эти ошибки & предупреждения:.React и React-Native версии конфликта при установке материала-UI

npm WARN peerDependencies The peer dependency [email protected]^15.1.0 included from react-addons-update will no 
npm WARN peerDependencies longer be automatically installed to fulfill the peerDependency 
npm WARN peerDependencies in npm 3+. Your application will need to depend on it explicitly. 
npm WARN peerDependencies The peer dependency [email protected]^15.1.0 included from react-addons-transition-group will no 
npm WARN peerDependencies longer be automatically installed to fulfill the peerDependency 
npm WARN peerDependencies in npm 3+. Your application will need to depend on it explicitly. 
npm WARN peerDependencies The peer dependency [email protected]^15.1.0 included from react-addons-create-fragment will no 
npm WARN peerDependencies longer be automatically installed to fulfill the peerDependency 
npm WARN peerDependencies in npm 3+. Your application will need to depend on it explicitly. 
npm ERR! Darwin 15.5.0 
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "material-ui" 
npm ERR! node v4.2.4 
npm ERR! npm v2.14.12 
npm ERR! code EPEERINVALID 

npm ERR! peerinvalid The package [email protected] does not satisfy its siblings' peerDependencies requirements! 
npm ERR! peerinvalid Peer [email protected] wants [email protected] 
npm ERR! peerinvalid Peer [email protected] wants [email protected]^15.1.0 
npm ERR! peerinvalid Peer [email protected] wants [email protected]^15.0.0-0 
npm ERR! peerinvalid Peer [email protected] wants [email protected]^15.0.0 

npm ERR! Please include the following file with any support request: 
npm ERR!  /Users/Ali/Desktop/app/second/npm-debug.log 

это кажется есть конфликт версий для использования последней версии Materil-интерфейс с последней среагировать родную сборкой

Есть ли кто-нибудь, кто понимает, что я могу сделать?

ответ

0

Я столкнулся с той же ошибкой с проектом React Native, который я инициализировал с помощью react-native init AwesomeProject.

Я отредактировал файл package.json, чтобы использовать более старую версию реакции, исправляя конфликт версий.

Вот мой package.json файл:

 
{ 
    "name": "AwesomeProject", 
    "version": "0.0.1", 
    "private": true, 
    "scripts": { 
    "start": "node node_modules/react-native/local-cli/cli.js start" 
    }, 
    "dependencies": { 
    "react": "^15.0.2", 
    "react-native": "^0.26.2", 
    "react-native-material-design": "^0.3.6" 
    } 
} 

Вы, возможно, потребуется удалить папку node_modules и запустить npm install снова.

Смежные вопросы