错误:规则只能有一个资源源(提供的资源和测试+包含+排除) [英] Error: Rule can only have one resource source (provided resource and test + include + exclude)
本文介绍了错误:规则只能有一个资源源(提供的资源和测试+包含+排除)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
您好,我有以下错误,我在 vuejs 中有一个应用程序,它工作正常,错误突然出现,重新安装所有内容,清理缓存,但我找不到解决方法,希望您的帮助
hello I have the following error, I have an app in vuejs, it was working fine, the error appeared suddenly, reinstalled everything, clean cache and I can't find a way to solve it, I hope your help
错误:规则中只能有一个资源源(提供的资源和测试+包含+排除)
Error: Rule can only have one resource source (provided resource and test + include + exclude) in
"exclude": [
null
],
"use": [
{
"loader": "/Users/juanpablo/front-treatments/node_modules/cache-loader/dist/cjs.js",
"options": {
"cacheDirectory": "/Users/juanpablo/front-treatments/node_modules/.cache/babel-loader",
"cacheIdentifier": "81fef5a6"
},
"ident": "clonedRuleSet-38[0].rules[0].use[0]"
},
{
"loader": "/Users/juanpablo/front-treatments/node_modules/babel-loader/lib/index.js",
"options": "undefined",
"ident": "undefined"
}
]
} ````
A complete log of this run can be found in:
0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli '/Users/juanpablo/.nvm/versions/node/v12.19.0/bin/node',
1 verbose cli '/Users/juanpablo/.nvm/versions/node/v12.19.0/bin/npm',
1 verbose cli 'run',
1 verbose cli 'serve'
1 verbose cli ]
2 info using npm@6.14.8
3 info using node@v12.19.0
4 verbose run-script [ 'preserve', 'serve', 'postserve' ]
5 info lifecycle vue-dashboard@0.1.0~preserve: vue-dashboard@0.1.0
6 info lifecycle vue-dashboard@0.1.0~serve: vue-dashboard@0.1.0
7 verbose lifecycle vue-dashboard@0.1.0~serve: unsafe-perm in lifecycle true
8 verbose lifecycle vue-dashboard@0.1.0~serve: PATH: /Users/juanpablo/.nvm/versions/node/v12.19.0/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Users/juanpablo/front-treatments/node_modules/.bin:/Users/juanpablo/.nvm/versions/node/v12.19.0/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/juanpablo/.rvm/bin
9 verbose lifecycle vue-dashboard@0.1.0~serve: CWD: /Users/juanpablo/front-treatments
10 silly lifecycle vue-dashboard@0.1.0~serve: Args: [ '-c', 'vue-cli-service serve' ]
11 silly lifecycle vue-dashboard@0.1.0~serve: Returned: code: 1 signal: null
12 info lifecycle vue-dashboard@0.1.0~serve: Failed to exec serve script
13 verbose stack Error: vue-dashboard@0.1.0 serve: `vue-cli-service serve`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (/Users/juanpablo/.nvm/versions/node/v12.19.0/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
13 verbose stack at EventEmitter.emit (events.js:314:20)
13 verbose stack at ChildProcess.<anonymous> (/Users/juanpablo/.nvm/versions/node/v12.19.0/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:314:20)
13 verbose stack at maybeClose (internal/child_process.js:1021:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5)
14 verbose pkgid vue-dashboard@0.1.0
15 verbose cwd /Users/juanpablo/front-treatments
16 verbose Darwin 19.6.0
17 verbose argv "/Users/juanpablo/.nvm/versions/node/v12.19.0/bin/node" "/Users/juanpablo/.nvm/versions/node/v12.19.0/bin/npm" "run" "serve"
18 verbose node v12.19.0
19 verbose npm v6.14.8
20 error code ELIFECYCLE
21 error errno 1
22 error vue-dashboard@0.1.0 serve: `vue-cli-service serve`
22 error Exit status 1
23 error Failed at the vue-dashboard@0.1.0 serve script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
推荐答案
谢谢你!
我刚刚遇到了同样的问题
I just had the same problem
删除 webpack 并安装以前的版本也对我有用!
Deleting webpack and installing previous version worked for me as well!
npm 卸载 webpack
npm install webpack@^4.0.0 --save-dev
这篇关于错误:规则只能有一个资源源(提供的资源和测试+包含+排除)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文