Uncaught Exception:
Error: The specified module could not be found.
\\?\C:\Users\Nardy\AppData\Local\Temp\9a606748-1d6f-4f6f-9b04-868284225d16.tmp.node
at process.func [as dlopen] (node:electron/js2c/asar_bundle:2:1822)
at Module._extensions..node (node:internal/modules/cjs/loader:1259:18)
at Object.func [as .node] (node:electron/js2c/asar_bundle:2:2049)
at Module.load (node:internal/modules/cjs/loader:1044:32)
at Module._load (node:internal/modules/cjs/loader:885:12)
at f._load (node:electron/js2c/asar_bundle:2:13330)
at Module.require (node:internal/modules/cjs/loader:1068:19)
at require (node:internal/modules/cjs/helpers:103:18)
at Object.<anonymous> (G:\Gitee\electron-vite\release\1.0.0\win-unpacked\resources\app.asar\node_modules\@jincan\iohook\index.cjs.js:4:21)
at Module._compile (node:internal/modules/cjs/loader:1174:14)
我的项目中引用了
.node
文件,在未使用electron-builder-encryptor
前,打包后electron程序可正常运行,但使用后却提示出错,错误信息如下:我检查过,在运行使用
electron-builder-encryptor
生成的程序时,C:\Users\Nardy\AppData\Local\Temp\9a606748-1d6f-4f6f-9b04-868284225d16.tmp.node
这个文件是存在的 我的系统是:Windows 11 NodeJS版本: v19.6.1