npm run dev 执行出错
来源:5-1 Nuxt.js基础(1)

风_863495732
2018-12-13
项目初始化完成后的提示 : npm notice created a lockfile as package-lock.json. You should commit this file.
npm run build 报错
ERROR in ./src/index.js
Module build failed (from ./node_modules/eslint-loader/index.js):
TypeError: Cannot read property ‘eslint’ of undefined
at Object.module.exports (D:\webpack\node_modules\eslint-loader\index.js:148:18)
3回答
-
风_863495732
提问者
2018-12-13
我用npm install eslint 安装了
00 -
风_863495732
提问者
2018-12-13
npm run dev 还是报错。我用 npm run build 报如下错误
ERROR in ./.nuxt/client.js
Module build failed (from ./node_modules/eslint-loader/index.js):
TypeError: Cannot read property 'eslint' of undefined
at Object.module.exports (C:\programs\vue-workspace\nuxt-learn\node_modules\eslint-loader\index.js:148:18)
@ multi ./.nuxt/client.js app[0]
FATAL Nuxt Build Error 09:58:26
╭────────────────────────╮
│ │
│ ✖ Nuxt Fatal Error │
│ │
│ Nuxt Build Error │
│ │
╰────────────────────────╯
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! nuxt-learn@1.1.0 build: `nuxt build && backpack build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the nuxt-learn@1.1.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
00 -
快乐动起来呀
2018-12-13
报错提示没有安装eslint,学会看报错提示哈
00
相似问题