报错说明
D:\ideaProjects\task-ui\node_modules\electron\index.js:17
throw new Error('Electron failed to install correctly, please delete node_modules/electron and try installing again');
^
Error: Electron failed to install correctly, please delete node_modules/electron and try installing again
at getElectronPath (D:\ideaProjects\task-ui\node_modules\electron\index.js:17:11)
at Object.<anonymous> (D:\ideaProjects\task-ui\node_modules\electron\index.js:21:18)
at Module._compile (internal/modules/cjs/loader.js:1137:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
at Module.load (internal/modules/cjs/loader.js:985:32)
at Function.Module._load (internal/modules/cjs/loader.js:878:14)
at Module.require (internal/modules/cjs/loader.js:1025:19)
at require (internal/modules/cjs/helpers.js:72:18)
at Object.<anonymous> (D:\ideaProjects\task-ui\.electron-vue\dev-runner.js:4:18)
at Module._compile (internal/modules/cjs/loader.js:1137:30)
调试查看报错信息
D:\ideaProjects\task-ui\node_modules\electron\index.js:17:11)
发现electron目录下没有这个path.txt
文件
进入\node_modules\electron
目录
执行安装命令node install
执行完成后发现该文件path.txt
已经有啦