tra*_*acy 10 javascript node.js npm node-modules npm-install
我在 Windows 10 中使用 npm run 命令时遇到此错误\n:
\nnode:internal/modules/cjs/loader:1063\n throw err;\n^\nError: Cannot find module 'D:\\mobile-version portfolio\\\nat Module._resolveFilename (node:internal/modules/cjs/loader:1060:15)\nat node:internal/main/check_syntax:34:20 {\n code: 'MODULE_NOT_FOUND',\n requireStack: []\n}\nRun Code Online (Sandbox Code Playgroud)\nNode.js v19.6.0 请有人帮助我。
\n我已经卸载并安装了node.js,但对我不起作用,我还删除了node-modules并再次安装,但一切都不起作用。
\n当我尝试运行任何 npm 命令,即 npm run start、npm run build 或使用 npx stylelint 检查 linter 错误时,**/*.{css,scss}它会抛出相同的错误。正在使用 webpack,我需要运行命令来更新 src 文件中 dist 文件中的更改。
我还需要运行并检查 linter 错误并在我的项目中修复。这是我的package.json文件:
"name": "to-do-list",\n "version": "1.0.0",\n "description": "README.md\\r One attachment\\r \xe2\x80\xa2 Scanned by Gmail\\r <a name=\\"readme-top\\"></a>",\n "main": "index.js",\n "private": true,\n "scripts": {\n "test": "echo \\"Error: no test specified\\" && exit 1",\n "start": "webpack serve --open",\n "build": "webpack --config webpack.config.js"\n },\n\n\n "repository": {\n "type": "git",\n "url": "git+https://github.com/Tracy-miranja/TO-DO-LIST.git"\n },\n "keywords": [],\n "author": "",\n "license": "ISC",\n "bugs": {\n "url": "https://github.com/Tracy-miranja/TO-DO-LIST/issues"\n },\n\n\n "homepage": "https://github.com/Tracy-miranja/TO-DO-LIST#readme",\n "devDependencies": {\n "@babel/core": "^7.17.8",\n "@babel/preset-env": "^7.16.11",\n "babel-eslint": "^10.1.0",\n "babel-loader": "^8.2.3",\n "css-loader": "^6.7.1",\n "eslint": "^7.32.0",\n "eslint-config-airbnb-base": "^14.2.1",\n "eslint-plugin-import": "^2.27.5",\n "hint": "^2.0.0",\n "html-webpack-plugin": "^5.5.0",\n "sass": "^1.49.9",\n "sass-loader": "^12.6.0",\n "style-loader": "^3.3.1",\n "stylelint": "^13.13.1",\n "stylelint-config-standard": "^21.0.0",\n "stylelint-csstree-validator": "^1.9.0",\n "stylelint-scss": "^3.21.0",\n "webpack": "^5.75.0",\n "webpack-bundle-analyzer": "^4.5.0",\n "webpack-cli": "^4.9.2",\n "webpack-dev-server": "^4.11.1"\n },\n\n\n "dependencies": {\n "lodash": "^4.17.21"\n }\n}\nRun Code Online (Sandbox Code Playgroud)\n
| 归档时间: |
|
| 查看次数: |
32485 次 |
| 最近记录: |