Reputation: 47
I am trying to create a Vue App with WebStorm in Mac. When I run the npm run dev
get this error:
npm ERR! missing script: dev
This is my package.json:
"version": "0.1.0",
"private": true,
"scripts": {
"serve": "vue-cli-service serve",
"build": "vue-cli-service build",
"lint": "vue-cli-service lint"
},
"dependencies": {
"vue": "^2.5.16"
},
"devDependencies": {
"@vue/cli-plugin-babel": "^3.0.0-beta.15",
"@vue/cli-plugin-eslint": "^3.0.0-beta.15",
"@vue/cli-service": "^3.0.0-beta.15",
"vue-template-compiler": "^2.5.16"
},
Upvotes: 1
Views: 1295
Reputation: 3383
That's because there's no dev
script in your package.json
. You should do npm run serve
. The available scripts are the following
// ...
"scripts": {
"serve": "vue-cli-service serve", // npm run serve
"build": "vue-cli-service build", // npm run build
"lint": "vue-cli-service lint" // npm run lint
},
// ...
Upvotes: 4