Closed callejoadrian closed 3 years ago
Did you check to see if the iohook binaries actually got installed in the install path (...\resources\app\node_modules\iohook\builds...)? If not then you probably just need to tweak your forge config. Are you using ASAR?
@marcelblum hi good day! btw i forgot to mention that iohook folder is missing in the install path. sorry I'm new in electron/node. how/what im going to update in my forge config? and probably, Im not using ASAR. thanks for the reply.
Is iohook listed in your package.json under dependencies
?
these are my dependencies. I also tried to add "iohook": "^0.9.1"
but an error occur when i tried to compile it.
Ok so sounds like since you compiled it yourself, you just manually placed a iohook folder in your node_modules and never did a npm install iohook
. Forge definitely won't automagically know to include iohook in your packaged app since it's not listed in your dependencies
. I think the easiest thing for you to do would be to create another node_modules folder inside your /src/ folder and move your custom iohook folder inside that /src/node_modules. That way it should be automatically included in your app package by Forge as part of your app's source code, and then it should be automatically found by your app when it does a require('iohook')
because require
will search that relative node_modules path for it.
Alternatively, you can use the extraResource option in your Forge packager config to specify that the iohook folder be copied over during the packaging process.
Yes. i just copy and paste the iohook binary file since npm install iohook
is not working.
_create another node_modules folder inside your /src/ folder and move your custom iohook folder inside that /src/nodemodules
this directions works for me. thanks for the help @marcelblum.
@callejoadrian why is npm install iohook
not working for you?
@ash0x0 I just tried it today. now its all working. but last time(maybe last 2 weeks?) I cannot download the package and it returns an 404 error message.
@ash0x0 thank you so much for the updates.
iohook is working properly in my development platform. Compiling the program is also working. But when I tried to install the .exe file this error appear...
If I remove the iohook in my program, the installation is successful and this message does not appear.
Expected Behavior
No problem on installation and iohook is working.
Current Behavior
error while installing the program
Possible Solution
Steps to Reproduce (for bugs)
Context
Your Environment