我有一个VueJS项目。我在MacBook(Mojave 10.14.6,节点8.9.4,npm 5.6.0)上运行时没有任何问题(npm install && yarn dev)。但是在Ubuntu 18.04(节点8.9.4,npm 5.6.0)上运行时存在问题
yarn run v1.17.3
$ cross-env NODE_ENV=development node build/dev-server.js
ERROR Failed to compile with 1 errors 06:57:46
This dependency was not found:
* !!babel-loader!./Payment.js in ./src/component/PayMent/PayMent.vue
To install it, you can run: npm install --save !!babel-loader!./Payment.js
> Listening at http://localhost:8686
我尝试过
npm install
npm install babel-loader
但是问题没有解决
package.json
"devDependencies": {
"async": "^2.2.0",
"autoprefixer": "^7.1.0",
"awesome-typescript-loader": "^3.1.2",
"babel-core": "^6.0.0",
"babel-eslint": "^8.0.0",
"babel-loader": "^7.0.0",
"babel-plugin-syntax-dynamic-import": "^6.18.0",
"babel-plugin-transform-builtin-extend": "^1.1.2",
"babel-plugin-transform-runtime": "^6.0.0",
"babel-preset-env": "^1.3.2",
"babel-preset-stage-2": "^6.0.0",
"babel-register": "^6.0.0",
"chalk": "^2.0.1",
"compression": "^1.6.2",
package-lock.json
"babel-loader": {
"version": "7.1.2"