首页 文章

安装React时出错

提问于
浏览
3

每当我做 npm init 然后 npm install react - 我收到此错误

──UNMETPEER DEPENDENCY react@15.3.0 npm WARN baobab-react@0.1.1要求对等人@> = 0.13.0 <1.0.0但没有安装 . npm WARN fixed-data-table@0.4.7要求反对@ @ = 0.13.0 <0.15.0 || ^ 0.14.0-beta3但没有安装 . npm WARN react-native@0.30.0需要一个react @〜15.2.0的对等方,但没有安装 . npm WARN react-router@0.13.5要求对等方为react@0.13.x||0.14.x但未安装任何对等方 . 错误的ERR!代码1

这是我的节点v6.3.0和npm 3.10.3版本 .

2 回答

  • 0
    npm install react --no-optional
    
  • 0

    在项目目录中,可以先运行以下命令: -

    1) rm -rf node_modules
    2) Try installig react again now and other packages which are in your package.json file.
    

相关问题