2017-04-24 3 views
0

バージョンはDependencyGraphの構築に失敗しましたとDependencyGraph

"react": "16.0.0-alpha.6", 
"react-native": "0.43.4", 
"react-native-router-flux": "^3.38.1" 

すべてが完璧に働いていたが、後にreact-native-router-flux すべてがあまりにも多くのエラーを与える死ぬインストールを構築するために失敗しました。

Failed to build DependencyGraph: @providesModule naming collision: 
    Duplicate module name: react-native 
    Paths: C:\Users\ashik\Desktop\react_apps\Friends\node_modules\react-native-router-flux\node_modules\react-native\ 
ackage.json collides with C:\Users\ashik\Desktop\react_apps\Friends\node_modules\react-native\package.json 

This error is caused by a @providesModule declaration with the same name across two different files. 
Error: @providesModule naming collision: 
    Duplicate module name: react-native 
    Paths: C:\Users\ashik\Desktop\react_apps\Friends\node_modules\react-native-router-flux\node_modules\react-native\ 
ackage.json collides with C:\Users\ashik\Desktop\react_apps\Friends\node_modules\react-native\package.json 

私はあまり質問を取得し、このエラー等答えるけど、私のリアクトネイティブバージョンとエラー同じであったではないか、私は解決策を理解していなかったが、すでにでした。私のために、より良い解決策や詳細を作りなさい。また、私はReact-nativeで新しく、Jsに反応します。

答えて

1

react-nativenavigation-experimental APIの安定版を使用できるように、react-native-router-fluxパッケージにはreact-nativeという独自の(フリーズした)コピーが含まれています。これにより、プロジェクトで使用されているreact-nativeのバージョンとの衝突が発生することがあります。また、3.38.1react-native-router-fluxのリリースでは、最近のバージョンのreact-nativeで問題が発生しているようです。可能な解決策は、react-native-router-flux3.38.0バージョンにダウングレードしています。ちょうどそのnode_modulesフォルダを削除してnpm installを実行して、あなたのpackage.json

"react-native-router-flux": "^3.38.1" 

"react-native-router-flux": "3.38.0" 

行を変更します。古いバージョンではこの問題は発生しません。

reference issue in the project repo

+0

#Pedro_Castilhoありがとうございました。本当にありがとうございました。私はすでに2時間以上試していますが、本当に大変助かります。 :) 私は** React-native **で新しくなっています**あなたが私のレッスンの提案をくれれば、それは私にとって素晴らしいことです。 –

関連する問題