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
*`worldId` Integer - The ID of the world to run the javascript in, `0` is the default world, `999` is the world used by Electrons `contextIsolation` feature. You can provide any integer here.
148
+
*`worldId` Integer - The ID of the world to run the javascript
149
+
in, `0` is the default main world (where content runs), `999` is the
150
+
world used by Electron's `contextIsolation` feature. Accepts values
151
+
in the range 1..536870911.
142
152
*`scripts`[WebSource[]](structures/web-source.md)
143
153
*`userGesture` Boolean (optional) - Default is `false`.
144
-
145
-
Returns `Promise<any>` - A promise that resolves with the result of the executed code
146
-
or is rejected if the result of the code is a rejected promise.
154
+
*`callback` Function (optional) - Called after script has been executed. Unless
155
+
the frame is suspended (e.g. showing a modal alert), execution will be
156
+
synchronous and the callback will be invoked before the method returns. For
157
+
compatibility with an older version of this method, the error parameter is
158
+
second.
159
+
*`result` Any
160
+
*`error` Error
161
+
162
+
Returns `Promise<any>` - A promise that resolves with the result of the executed
163
+
code or is rejected if execution throws or results in a rejected promise.
147
164
148
165
Works like `executeJavaScript` but evaluates `scripts` in an isolated context.
0 commit comments