node用npm命令安装依赖和启动项目都会报错,从新拉取代码也一样报错,删除mode_modules包再用npm install 报错,用cnpm安装也一样报错。
问题相关代码,请勿粘贴截图
Administrator@MS-KLPESEFQMSZF MINGW64 ~/Desktop/insurance-official (v1.2)
$ npm run dev
(node:2372) UnhandledPromiseRejectionWarning: Error: EIO: i/o error, read
at Object.readSync (fs.js:617:3)
at tryReadSync (fs.js:382:20)
at Object.readFileSync (fs.js:411:19)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1112:18)
at Module.load (internal/modules/cjs/loader.js:950:32)
at Function.Module._load (internal/modules/cjs/loader.js:790:12)
at Module.require (internal/modules/cjs/loader.js:974:19)
at require (internal/modules/cjs/helpers.js:93:18)
at Object.<anonymous> (C:\Users\Administrator\AppData\Roaming\npm\node_modules\npm\node_modules\chalk\source\index.js:7:5)
at Module._compile (internal/modules/cjs/loader.js:1085:14)
(Use `node --trace-warnings ...` to show where the warning was created)
(node:2372) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:2372) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
Administrator@MS-KLPESEFQMSZF MINGW64 ~/Desktop/insurance-official (v1.2)
$ npm i
(node:14612) UnhandledPromiseRejectionWarning: Error: EIO: i/o error, read
at Object.readSync (fs.js:617:3)
at tryReadSync (fs.js:382:20)
at Object.readFileSync (fs.js:411:19)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1112:18)
at Module.load (internal/modules/cjs/loader.js:950:32)
at Function.Module._load (internal/modules/cjs/loader.js:790:12)
at Module.require (internal/modules/cjs/loader.js:974:19)
at require (internal/modules/cjs/helpers.js:93:18)
at Object.<anonymous> (C:\Users\Administrator\AppData\Roaming\npm\node_modules\npm\node_modules\chalk\source\index.js:7:5)
at Module._compile (internal/modules/cjs/loader.js:1085:14)
(Use `node --trace-warnings ...` to show where the warning was created)
(node:14612) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:14612) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
我的解答思路和尝试过的方法
我想要达到的结果