我正在尝试使用诸如“包裹监视./public/js/index.js --out-dir ./public/js --out-file bundle.js"
”之类的包裹命令,但显示错误
这是我的package.json
{
"name": "natours",
"version": "1.0.0",
"description": "learing nodejs, express and mongoDB",
"main": "app.js",
"scripts": {
"start": "nodemon server.js",
"start:prod": "NODE_ENV=production nodemon server.js",
"debug": "ndb server.js",
"watch:js": "parcel watch ./public/js/index.js --out-dir ./public/js --out-file bundle.js",
"build:js": "parcel watch ./public/js/index.js --out-dir ./public/js --out-file bundle.js"
},
"author": "Nayan Pujara",
"license": "ISC",
"dependencies": {
"bcryptjs": "^2.4.3",
"cookie-parser": "^1.4.5",
"dotenv": "^8.2.0",
"env-variable": "0.0.6",
"express": "^4.17.1",
"express-mongo-sanitize": "^2.0.0",
"express-rate-limit": "^5.1.3",
"helmet": "^3.23.0",
"hpp": "^0.2.3",
"jsonwebtoken": "^8.5.1",
"mongoose": "^5.9.16",
"morgan": "^1.10.0",
"nodemailer": "^6.4.8",
"pug": "^3.0.0",
"slugify": "^1.4.0",
"validator": "^13.0.0",
"xss-clean": "^0.1.1"
},
"devDependencies": {
"eslint": "^5.16.0",
"eslint-config-airbnb": "^17.1.0",
"eslint-config-prettier": "^4.1.0",
"eslint-plugin-import": "^2.17.2",
"eslint-plugin-jsx-a11y": "^6.2.1",
"eslint-plugin-node": "^8.0.1",
"eslint-plugin-prettier": "^3.0.1",
"eslint-plugin-react": "^7.12.4",
"ndb": "^1.1.5",
"parcel-bundler": "^1.12.4",
"prettier": "^1.17.0"
},
"engines": {
"node": ">=10.0.0"
}
}
这是我得到的错误
D:\Download\Knoledgeable video\[FreeTutorials.Us] Udemy - Node.js, Express, MongoDB & More The Complete Bootcamp 2019\complete-node-bootcamp-master\**complete-node-bootcamp-master\4-natours\starter>parcel watch ./public/js/index.js --out-dir ./public/js --out-file bundle.js**
×
Cannot resolve entry "D:\Download\Knoledgeable video\[FreeTutorials.Us] Udemy - Node.js, Express, MongoDB & More The Complete Bootcamp 2019\complete-node-bootcamp-master\complete-node-bootcamp-master\4-natours\starter\public\js\index.js" from "D:\Download\Knoledgeable video\[FreeTutorials.Us] Udemy - Node.js, Express, MongoDB & More The Complete Bootcamp 2019\complete-node-bootcamp-master\complete-node-bootcamp-master\4-natours\starter\public\js"
at Bundler.bundle (C:\Users\stifl\AppData\Roaming\npm\node_modules\parcel-bundler\src\Bundler.js:268:19)
已经通过多种方式取消安装和多次安装