gpt4 book ai didi

vue.js - 我无法在 Vuejs 中运行开发服务器

转载 作者:搜寻专家 更新时间:2023-10-30 22:49:33 26 4
gpt4 key购买 nike

我将 webpack-simple 模板与 vue-cli 一起使用,但在安装后我尝试使用

npm run serve

此错误代码存在。

C:\Users\Utku\Desktop\workarea\vuejs\vue-cli-intro\node_modules\depd\index.js:399
throw new TypeError('argument fn must be a function')
^

TypeError: argument fn must be a function
at Function.wrapfunction [as function] (C:\Users\Utku\Desktop\workarea\vuejs\vue-cli-intro\node_modules\depd\index.js:399:11)
at populateConstructorExports (C:\Users\Utku\Desktop\workarea\vuejs\vue-cli-intro\node_modules\http-errors\index.js:264:45)
at Object.<anonymous> (C:\Users\Utku\Desktop\workarea\vuejs\vue-cli-intro\node_modules\http-errors\index.js:30:1)
at Module._compile (internal/modules/cjs/loader.js:776:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10)
at Module.load (internal/modules/cjs/loader.js:643:32)
at Function.Module._load (internal/modules/cjs/loader.js:556:12)
at Module.require (internal/modules/cjs/loader.js:683:19)
at require (internal/modules/cjs/helpers.js:16:16)
at Object.<anonymous> (C:\Users\Utku\Desktop\workarea\vuejs\vue-cli-intro\node_modules\send\index.js:15:19)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! vue-cli-intro@1.0.0 dev: `cross-env NODE_ENV=development webpack-dev-server --open --hot`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the vue-cli-intro@1.0.0 dev script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
``

最佳答案

{
"name": "vue-cli-intro",
"version": "0.1.0",
"private": true,
"scripts": {
"serve": "vue-cli-service serve",
"build": "vue-cli-service build",
"lint": "vue-cli-service lint"
},
"dependencies": {
"core-js": "^2.6.5",
"vue": "^2.6.10"
},
"devDependencies": {
"@vue/cli-plugin-babel": "^3.9.0",
"@vue/cli-plugin-eslint": "^3.9.0",
"@vue/cli-service": "^3.9.0",
"babel-eslint": "^10.0.1",
"eslint": "^5.16.0",
"eslint-plugin-vue": "^5.0.0",
"vue-template-compiler": "^2.6.10"
},
"eslintConfig": {
"root": true,
"env": {
"node": true
},
"extends": [
"plugin:vue/essential",
"eslint:recommended"
],
"rules": {},
"parserOptions": {
"parser": "babel-eslint"
}
},
"postcss": {
"plugins": {
"autoprefixer": {}
}
},
"browserslist": [
"> 1%",
"last 2 versions"
]
}

关于vue.js - 我无法在 Vuejs 中运行开发服务器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56870803/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com