-
-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Usage in electron #106
Comments
Hi @HulioEglesias, thanks for reaching out! Could you please provide additional info regarding your setup?
Best regards Simon |
Windows 10 version 1809(build 17763.1039) |
Would it be possible to provide the sample application in a repository? @HulioEglesias Tried to use your download link, but it does not work. |
I have same error
with Electron quick start example below is my change code in main.js const {app, BrowserWindow,ipcMain} = require('electron')
const path = require('path')
const {
mouse,
left,
right,
up,
down
} = require('@nut-tree/nut-js');
function createWindow () {
// Create the browser window.
const mainWindow = new BrowserWindow({
width: 800,
height: 600,
webPreferences: {
preload: path.join(__dirname, 'preload.js')
}
}) and my env Windows 10 version 1809(build 17763.1158) |
Hi @bluedarker,
I did not yet spend time on this, but it would require additional build configs for multiple modules. As always, contributions are very welcome! :) Best regards Simon |
Hi @bluedarker and @HulioEglesias, I published a next release of nut.js which comes with Electron compatible bindings. Feel free to give it a try and let me know! Sample:
|
@s1hofmann Thank you so much for you help and contribution, I will make a try and let you know the result within this week. |
@s1hofmann I have tried through different way, including electron-rebuild, electron-builder, node-gyp build and re-init after rm node_modules folder, same thing happened. I know little about native module, it seems to me that rebuilding @nut-tree\libnut-win32\build\Release\libnut.node is needed. But there is no install.js provided in @nut-tree\libnut-win32. Any of your replay is very much appreciated. Could you provide me your ENV for my reference? Following is my ENV: Windows 10 version 1809(build 17763.1158) |
Hi @bluedarker, I just set up a Windows VM and unfortunately, I can confirm your problem. Although I'm having an assumption what might cause this problem, I'll have to investigate on it. Would you mind opening a separate issue for Electron + Windows problems? Thanks for your input! Best regards Simon Edit: I guess my assumption was right: nodejs/node-addon-api#269 (comment) |
Hi @s1hofmann, |
When I try to start by electron, I got an error
The text was updated successfully, but these errors were encountered: