You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello everyone.
I am new on electron and trying to update an electron project from v11.5.0 to latest version (or at least last 17 sub version).
My setup:
"node": "14.16"
"@electron/remote": "^2.0.8",
"electron": "^12.0.0", (same issue with 13.6.9 or 17.3.1)
I am facing an issue trying to move from enableRemoteModule (in BrowserWindow's webPreferences) to enable(webContents).
Here it is about a notification windows which should be opened and display the right content.
I stay on electron 12.0.0/13.6.9 in order to switch easily from one to the other.
I probably miss something important.
In preload.js, with enableRemoteModule: true, every thing works fine, my notification window open and is filled up with its content. Using enable, my notification window open but nothing is displayed in it. I do not have any console warning or error.
In main, using enable seems to work.
I guess it could be related to an initialization issue.
I do not know if it could help but I noticed that remoteMain.enable(win.webContents) in main returns null and remote.require("@electron/remote/main").enable(win.webContents) returns undefined in preload even if both emoteMain.enable and remote.require("@electron/remote/main").enable return the same exact function.
The text was updated successfully, but these errors were encountered:
Hello everyone.
I am new on electron and trying to update an electron project from v11.5.0 to latest version (or at least last 17 sub version).
My setup:
"node": "14.16"
"@electron/remote": "^2.0.8",
"electron": "^12.0.0", (same issue with 13.6.9 or 17.3.1)
I am facing an issue trying to move from
enableRemoteModule
(in BrowserWindow's webPreferences) toenable(webContents)
.Here it is about a notification windows which should be opened and display the right content.
I stay on electron 12.0.0/13.6.9 in order to switch easily from one to the other.
Before (enableRemoteModule)
main:
preload
After (enable)
main:
preload:
I probably miss something important.
In preload.js, with enableRemoteModule: true, every thing works fine, my notification window open and is filled up with its content. Using enable, my notification window open but nothing is displayed in it. I do not have any console warning or error.
In main, using enable seems to work.
I guess it could be related to an initialization issue.
I do not know if it could help but I noticed that remoteMain.enable(win.webContents) in main returns null and remote.require("@electron/remote/main").enable(win.webContents) returns undefined in preload even if both emoteMain.enable and remote.require("@electron/remote/main").enable return the same exact function.
The text was updated successfully, but these errors were encountered: