流星客户端捆绑程序错误:找不到模块“反应”

时间:2018-12-11 13:08:42

标签: reactjs meteor meteor-react

我使用create-react-app创建了一个项目,并安装了流星客户端捆绑程序https://github.com/Urigo/meteor-client-bundler

一切正常。我添加了一个新的依赖项,然后再次运行"mcb": "meteor-client bundle --config=meteor-client.config.json",现在出现此错误。我该怎么办?error screenshot

这是我的meteor-client.config.json:

{
  "runtime": {
    "DDP_DEFAULT_CONNECTION_URL": "http://localhost:3000/"
  },
  "import": [
    "meteor-base",
    "mongo",
    "cfs:standard-packages",
    "cfs:gridfs",
    "react-meteor-data"
  ],
  "externalNpmPackages": ["@babel/runtime", "meteor-node-stubs", "@react"],
  "npmInstall": false,
  "generateNodeModules": true
}

和package.json:

{
  "name": "meteor-client-bundler-test",
  "version": "0.1.0",
  "private": true,
  "dependencies": {
    "meteor-client-bundler": "^0.6.0",
    "meteor-node-stubs": "^0.4.1",
    "react": "^16.6.3",
    "react-dom": "^16.6.3",
    "react-scripts": "2.1.1"
  },
  "scripts": {
    "start": "react-scripts start",
    "build": "react-scripts build",
    "test": "react-scripts test",
    "eject": "react-scripts eject",
    "mcb": "meteor-client bundle --config=meteor-client.config.json"
  },
  "eslintConfig": {
    "extends": "react-app"
  },
  "browserslist": [
    ">0.2%",
    "not dead",
    "not ie <= 11",
    "not op_mini all"
  ]
}

链接到我的项目,出现错误https://github.com/Phazeoner/meteor-client-bundler-test

0 个答案:

没有答案