npm run dev 报错
发布于 7 年前 作者 huyuan 4672 次浏览 来自 问答
粉丝福利 : 关注VUE中文社区公众号,回复视频领取粉丝福利

huazhuhotel@1.0.0 dev C:\Users\Thinkpad\Desktop\huazhuhotel node build/dev-server.js

npm WARN invalid config registry="" npm WARN invalid config Must be a full url with ‘http://’ C:\Users\Thinkpad\Desktop\huazhuhotel\node_modules\webpack\lib\webpack.js:19 throw new WebpackOptionsValidationError(webpackOptionsValidationErrors); ^

WebpackOptionsValidationError: Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.

  • configuration.entry should be one of these: object { <key>: non-empty string | [non-empty string] } | non-empty string | [non-empty string] | function The entry point(s) of the compilation. Details:
    • configuration.entry should be an object.
    • configuration.entry should be a string.
    • configuration.entry[0] should be a string.
    • configuration.entry[1] should be a string.
    • configuration.entry should be an instance of function function returning an entry object or a promise… at webpack (C:\Users\Thinkpad\Desktop\huazhuhotel\node_modules\webpack\lib\webpack.js:19:9) at Object.<anonymous> (C:\Users\Thinkpad\Desktop\huazhuhotel\build\dev-server.js:24:16) at Module._compile (module.js:573:30) at Object.Module._extensions…js (module.js:584:10) at Module.load (module.js:507:32) at tryModuleLoad (module.js:470:12) at Function.Module._load (module.js:462:3) at Function.Module.runMain (module.js:609:10) at startup (bootstrap_node.js:158:16) at bootstrap_node.js:598:3 npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! huazhuhotel@1.0.0 dev: node build/dev-server.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the huazhuhotel@1.0.0 dev script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\Thinkpad\AppData\Roaming\npm-cache_logs\2017-09-06T05_11_20_141Z-debug.log

回到顶部