0

​可以轻松地将 NPM 模块添加到 Gatsby。

例如:

gatsby new lumen https://github.com/wpioneer/gatsby-starter-lumen 
cd lumen 
npm install react-router-component-transition --save

├── UNMET PEER DEPENDENCY react@15.3.1 
├── UNMET PEER DEPENDENCY react-addons-css-transition-group@^0.14.0 
├── UNMET PEER DEPENDENCY react-router-component@>=0.27 
└─┬ react-router-component-transition@0.2.0   
  └─┬ object.assign@4.0.4
    ├─┬ define-properties@1.1.2
    │ ├── foreach@2.0.5
    │ └── object-keys@1.0.11
    └── object-keys@1.0.11

npm WARN react-router-component-transition@0.2.0 requires a peer of react-router-component@>=0.27 but none was installed. 
npm WARN react-router-component-transition@0.2.0 requires a peer of react@^0.14.0 but none was installed. 
npm WARN react-router-component-transition@0.2.0 requires a peer of react-addons-css-transition-group@^0.14.0 but none was installed. 
npm WARN gatsby-starter-lumen@1.1.0 No repository field.

我尝试并得到了一些对等依赖错误。

4

1 回答 1

0

此外,这些只是警告 Gatsby 包通常不会处于最前沿,如果那是你为 npm 和 node 运行的包。

于 2018-06-24T01:49:05.300 回答