首页 > 解决方案 > 安装 parallelshell@3.0.2 和 onchange@7.1.0 后尝试运行 npm start 时遇到问题

问题描述

这是我的 package.json 文件 -->

{
  "name": "aboutus",
  "version": "1.0.0",
  "description": "This is a website for Ristorante Con Fusion",
  "main": "index.html",
  "scripts": {
    "start": "npm run watch:all",
    "test": "echo \"Error: no test specified\" && exit 1",
    "lite": "lite-server",
    "scss": "node-sass -o css/ css/",
    "watch:scss": "onchange \"css/*.scss\" --npm run scss",
    "watch:all": "parallelshell \"npm run watch:scss\" \"npm run lite\" "
  },
  "author": "",
  "license": "ISC",
  "devDependencies": {
    "lite-server": "^2.3.0",
    "node-sass": "^5.0.0",
    "onchange": "^7.1.0",
    "parallelshell": "^3.0.2"
  },
  "dependencies": {
    "bootstrap": "^4.0.0",
    "bootstrap-social": "^5.1.1",
    "font-awesome": "^4.7.0",
    "jquery": "^3.3.1",
    "popper.js": "^1.16.1"
  }
}

这是我得到的错误,请帮助!

在此处输入图像描述

标签: sassnode-modulesweb-deploymentonchangenpm-scripts

解决方案


这是parallelshell版本的问题,写这个:

npm install --save-dev onchange@3.3.0 parallelshell@3.0.1

它会解决你的问题。


推荐阅读