From e70268830b875779a0a028b30e806bb4374801c9 Mon Sep 17 00:00:00 2001 From: electron-bot Date: Wed, 13 May 2020 18:05:27 +0000 Subject: [PATCH] feat: update source content --- .../docs/api/structures/new-window-event.md | 4 + content/7-2-x/en-US/docs/api/web-contents.md | 2 +- content/9-x-y/en-US/docs/README.md | 1 + content/9-x-y/en-US/docs/api/accelerator.md | 2 +- content/9-x-y/en-US/docs/api/app.md | 17 +- .../9-x-y/en-US/docs/api/browser-window.md | 53 +- .../9-x-y/en-US/docs/api/crash-reporter.md | 161 +++--- .../en-US/docs/api/environment-variables.md | 11 + .../en-US}/docs/api/extensions.md | 34 +- .../9-x-y/en-US/docs/api/frameless-window.md | 4 +- content/9-x-y/en-US/docs/api/menu-item.md | 6 +- .../api/modernization/property-updates.md | 7 - .../9-x-y/en-US/docs/api/sandbox-option.md | 2 +- .../docs/api/structures/new-window-event.md | 4 + .../en-US/docs/api/system-preferences.md | 2 +- content/9-x-y/en-US/docs/api/web-contents.md | 2 +- content/9-x-y/en-US/docs/breaking-changes.md | 185 +++++-- .../development/build-instructions-linux.md | 2 +- .../development/build-instructions-macos.md | 2 +- .../debugging-instructions-macos.md | 2 +- .../en-US/docs/development/pull-requests.md | 2 +- .../9-x-y/en-US/docs/tutorial/installation.md | 2 +- .../9-x-y/en-US/docs/tutorial/macos-dock.md | 2 +- .../docs/tutorial/testing-widevine-cdm.md | 2 +- .../ar-SA/docs/api/message-channel-main.md | 26 - .../ar-SA/docs/api/message-port-main.md | 44 -- .../current/ar-SA/docs/api/service-workers.md | 61 --- .../ar-SA/docs/api/structures/extension.md | 8 - .../ar-SA/docs/api/structures/post-body.md | 19 - .../ar-SA/docs/api/structures/post-data.md | 12 - .../api/structures/service-worker-info.md | 5 - .../docs/api/touch-bar-other-items-proxy.md | 9 - content/current/bg-BG/docs/api/extensions.md | 87 ---- .../bg-BG/docs/api/message-channel-main.md | 26 - .../bg-BG/docs/api/message-port-main.md | 44 -- .../current/bg-BG/docs/api/service-workers.md | 61 --- .../bg-BG/docs/api/structures/extension.md | 8 - .../bg-BG/docs/api/structures/post-body.md | 19 - .../bg-BG/docs/api/structures/post-data.md | 12 - .../api/structures/service-worker-info.md | 5 - .../docs/api/touch-bar-other-items-proxy.md | 9 - content/current/cs-CZ/docs/api/extensions.md | 87 ---- .../cs-CZ/docs/api/message-channel-main.md | 26 - .../cs-CZ/docs/api/message-port-main.md | 44 -- .../current/cs-CZ/docs/api/service-workers.md | 61 --- .../cs-CZ/docs/api/structures/extension.md | 8 - .../cs-CZ/docs/api/structures/post-body.md | 19 - .../cs-CZ/docs/api/structures/post-data.md | 12 - .../api/structures/service-worker-info.md | 5 - .../docs/api/touch-bar-other-items-proxy.md | 9 - .../current/en-US/docs/api/web-contents.md | 2 +- .../current/en-US/docs/breaking-changes.md | 65 +++ .../docs/development/build-instructions-gn.md | 25 +- .../en-US/docs/tutorial/context-isolation.md | 70 +++ .../en-US/docs/tutorial/devtools-extension.md | 2 +- .../en-US/docs/tutorial/performance.md | 4 +- .../current/en-US/docs/tutorial/security.md | 47 +- .../en-US/docs/tutorial/spellchecker.md | 74 +++ .../current/en-US/docs/tutorial/updates.md | 8 +- content/current/en-US/electron-api.json | 469 +++++++++--------- .../en-US/website/blog/cadence-pause.md | 4 +- content/current/en-US/website/locale.yml | 19 +- content/current/zh-CN/docs/api/extensions.md | 87 ---- .../zh-CN/docs/api/message-channel-main.md | 26 - .../zh-CN/docs/api/message-port-main.md | 44 -- .../current/zh-CN/docs/api/service-workers.md | 61 --- .../zh-CN/docs/api/structures/extension.md | 8 - .../zh-CN/docs/api/structures/post-body.md | 19 - .../zh-CN/docs/api/structures/post-data.md | 12 - .../api/structures/service-worker-info.md | 5 - .../docs/api/touch-bar-other-items-proxy.md | 9 - content/current/zh-TW/docs/api/extensions.md | 87 ---- .../zh-TW/docs/api/message-channel-main.md | 26 - .../zh-TW/docs/api/message-port-main.md | 44 -- .../current/zh-TW/docs/api/service-workers.md | 61 --- .../zh-TW/docs/api/structures/extension.md | 8 - .../zh-TW/docs/api/structures/post-body.md | 19 - .../zh-TW/docs/api/structures/post-data.md | 12 - .../api/structures/service-worker-info.md | 5 - .../docs/api/touch-bar-other-items-proxy.md | 9 - lib/parsers/docs-parser.ts | 2 +- package.json | 6 +- stats.json | 106 ++-- wordcount.md | 22 +- 84 files changed, 922 insertions(+), 1782 deletions(-) create mode 100644 content/7-2-x/en-US/docs/api/structures/new-window-event.md rename content/{current/ar-SA => 9-x-y/en-US}/docs/api/extensions.md (62%) create mode 100644 content/9-x-y/en-US/docs/api/structures/new-window-event.md delete mode 100644 content/current/ar-SA/docs/api/message-channel-main.md delete mode 100644 content/current/ar-SA/docs/api/message-port-main.md delete mode 100644 content/current/ar-SA/docs/api/service-workers.md delete mode 100644 content/current/ar-SA/docs/api/structures/extension.md delete mode 100644 content/current/ar-SA/docs/api/structures/post-body.md delete mode 100644 content/current/ar-SA/docs/api/structures/post-data.md delete mode 100644 content/current/ar-SA/docs/api/structures/service-worker-info.md delete mode 100644 content/current/ar-SA/docs/api/touch-bar-other-items-proxy.md delete mode 100644 content/current/bg-BG/docs/api/extensions.md delete mode 100644 content/current/bg-BG/docs/api/message-channel-main.md delete mode 100644 content/current/bg-BG/docs/api/message-port-main.md delete mode 100644 content/current/bg-BG/docs/api/service-workers.md delete mode 100644 content/current/bg-BG/docs/api/structures/extension.md delete mode 100644 content/current/bg-BG/docs/api/structures/post-body.md delete mode 100644 content/current/bg-BG/docs/api/structures/post-data.md delete mode 100644 content/current/bg-BG/docs/api/structures/service-worker-info.md delete mode 100644 content/current/bg-BG/docs/api/touch-bar-other-items-proxy.md delete mode 100644 content/current/cs-CZ/docs/api/extensions.md delete mode 100644 content/current/cs-CZ/docs/api/message-channel-main.md delete mode 100644 content/current/cs-CZ/docs/api/message-port-main.md delete mode 100644 content/current/cs-CZ/docs/api/service-workers.md delete mode 100644 content/current/cs-CZ/docs/api/structures/extension.md delete mode 100644 content/current/cs-CZ/docs/api/structures/post-body.md delete mode 100644 content/current/cs-CZ/docs/api/structures/post-data.md delete mode 100644 content/current/cs-CZ/docs/api/structures/service-worker-info.md delete mode 100644 content/current/cs-CZ/docs/api/touch-bar-other-items-proxy.md create mode 100644 content/current/en-US/docs/tutorial/context-isolation.md create mode 100644 content/current/en-US/docs/tutorial/spellchecker.md delete mode 100644 content/current/zh-CN/docs/api/extensions.md delete mode 100644 content/current/zh-CN/docs/api/message-channel-main.md delete mode 100644 content/current/zh-CN/docs/api/message-port-main.md delete mode 100644 content/current/zh-CN/docs/api/service-workers.md delete mode 100644 content/current/zh-CN/docs/api/structures/extension.md delete mode 100644 content/current/zh-CN/docs/api/structures/post-body.md delete mode 100644 content/current/zh-CN/docs/api/structures/post-data.md delete mode 100644 content/current/zh-CN/docs/api/structures/service-worker-info.md delete mode 100644 content/current/zh-CN/docs/api/touch-bar-other-items-proxy.md delete mode 100644 content/current/zh-TW/docs/api/extensions.md delete mode 100644 content/current/zh-TW/docs/api/message-channel-main.md delete mode 100644 content/current/zh-TW/docs/api/message-port-main.md delete mode 100644 content/current/zh-TW/docs/api/service-workers.md delete mode 100644 content/current/zh-TW/docs/api/structures/extension.md delete mode 100644 content/current/zh-TW/docs/api/structures/post-body.md delete mode 100644 content/current/zh-TW/docs/api/structures/post-data.md delete mode 100644 content/current/zh-TW/docs/api/structures/service-worker-info.md delete mode 100644 content/current/zh-TW/docs/api/touch-bar-other-items-proxy.md diff --git a/content/7-2-x/en-US/docs/api/structures/new-window-event.md b/content/7-2-x/en-US/docs/api/structures/new-window-event.md new file mode 100644 index 0000000000000..b3939a00785a1 --- /dev/null +++ b/content/7-2-x/en-US/docs/api/structures/new-window-event.md @@ -0,0 +1,4 @@ +# NewWindowEvent Object extends `Event` + +* `newGuest` BrowserWindow (optional) + diff --git a/content/7-2-x/en-US/docs/api/web-contents.md b/content/7-2-x/en-US/docs/api/web-contents.md index e5af169b95e61..32b7c31a1be1e 100644 --- a/content/7-2-x/en-US/docs/api/web-contents.md +++ b/content/7-2-x/en-US/docs/api/web-contents.md @@ -138,7 +138,7 @@ Emitted when page receives favicon urls. Returns: -* `event` Event +* `event` NewWindowEvent * `url` String * `frameName` String * `disposition` String - Can be `default`, `foreground-tab`, `background-tab`, diff --git a/content/9-x-y/en-US/docs/README.md b/content/9-x-y/en-US/docs/README.md index 79e94a3985c1a..8e59dad89c816 100644 --- a/content/9-x-y/en-US/docs/README.md +++ b/content/9-x-y/en-US/docs/README.md @@ -112,6 +112,7 @@ These individual tutorials expand on topics discussed in the guide above. * [Process Object](api/process.md) * [Supported Command Line Switches](api/command-line-switches.md) * [Environment Variables](api/environment-variables.md) +* [Chrome Extensions Support](api/extensions.md) * [Breaking API Changes](breaking-changes.md) ### Custom DOM Elements: diff --git a/content/9-x-y/en-US/docs/api/accelerator.md b/content/9-x-y/en-US/docs/api/accelerator.md index 8a5b1c92e377a..6c5dfd1a4bfe6 100644 --- a/content/9-x-y/en-US/docs/api/accelerator.md +++ b/content/9-x-y/en-US/docs/api/accelerator.md @@ -54,7 +54,7 @@ The `Super` key is mapped to the `Windows` key on Windows and Linux and * `0` to `9` * `A` to `Z` * `F1` to `F24` -* Punctuations like `~`, `!`, `@`, `#`, `$`, etc. +* Punctuation like `~`, `!`, `@`, `#`, `$`, etc. * `Plus` * `Space` * `Tab` diff --git a/content/9-x-y/en-US/docs/api/app.md b/content/9-x-y/en-US/docs/api/app.md index 79f4f9d401c05..a43783356f8f8 100644 --- a/content/9-x-y/en-US/docs/api/app.md +++ b/content/9-x-y/en-US/docs/api/app.md @@ -75,7 +75,7 @@ Returns: * `event` Event Emitted when all windows have been closed and the application will quit. -Calling `event.preventDefault()` will prevent the default behaviour, which is +Calling `event.preventDefault()` will prevent the default behavior, which is terminating the application. See the description of the `window-all-closed` event for the differences between @@ -204,7 +204,7 @@ Returns: [`NSUserActivity.activityType`][activity-type]. * `userInfo` unknown - Contains app-specific state stored by the activity. -Emitted when [Handoff][handoff] is about to be resumed on another device. If you need to update the state to be transferred, you should call `event.preventDefault()` immediately, construct a new `userInfo` dictionary and call `app.updateCurrentActiviy()` in a timely manner. Otherwise, the operation will fail and `continue-activity-error` will be called. +Emitted when [Handoff][handoff] is about to be resumed on another device. If you need to update the state to be transferred, you should call `event.preventDefault()` immediately, construct a new `userInfo` dictionary and call `app.updateCurrentActivity()` in a timely manner. Otherwise, the operation will fail and `continue-activity-error` will be called. ### Event: 'new-window-for-tab' _macOS_ @@ -554,11 +554,17 @@ Returns `Promise` - fulfilled when Electron is initialized. May be used as a convenient alternative to checking `app.isReady()` and subscribing to the `ready` event if the app is not ready yet. -### `app.focus()` +### `app.focus([options])` + +* `options` Object (optional) + * `steal` Boolean _macOS_ - Make the receiver the active app even if another app is + currently active. On Linux, focuses on the first visible window. On macOS, makes the application the active app. On Windows, focuses on the application's first window. +You should seek to use the `steal` option as sparingly as possible. + ### `app.hide()` _macOS_ Hides all application windows without minimizing them. @@ -602,6 +608,7 @@ Returns `String` - The current application directory. * `videos` Directory for a user's videos. * `logs` Directory for your app's log folder. * `pepperFlashSystemPlugin` Full path to the system version of the Pepper Flash plugin. + * `crashDumps` Directory where crash dumps are stored. Returns `String` - A path to a special directory or file associated with `name`. On failure, an `Error` is thrown. @@ -1021,7 +1028,7 @@ This method can only be called before app is ready. By default, Chromium disables 3D APIs (e.g. WebGL) until restart on a per domain basis if the GPU processes crashes too frequently. This function -disables that behaviour. +disables that behavior. This method can only be called before app is ready. @@ -1190,7 +1197,7 @@ Show the app's about panel options. These options can be overridden with `app.se * `website` String (optional) _Linux_ - The app's website. * `iconPath` String (optional) _Linux_ _Windows_ - Path to the app's icon. On Linux, will be shown as 64x64 pixels while retaining aspect ratio. -Set the about panel options. This will override the values defined in the app's `.plist` file on MacOS. See the [Apple docs][about-panel-options] for more details. On Linux, values must be set in order to be shown; there are no defaults. +Set the about panel options. This will override the values defined in the app's `.plist` file on macOS. See the [Apple docs][about-panel-options] for more details. On Linux, values must be set in order to be shown; there are no defaults. If you do not set `credits` but still wish to surface them in your app, AppKit will look for a file named "Credits.html", "Credits.rtf", and "Credits.rtfd", in that order, in the bundle returned by the NSBundle class method main. The first file found is used, and if none is found, the info area is left blank. See Apple [documentation](https://developer.apple.com/documentation/appkit/nsaboutpaneloptioncredits?language=objc) for more information. diff --git a/content/9-x-y/en-US/docs/api/browser-window.md b/content/9-x-y/en-US/docs/api/browser-window.md index 4bf9e4ee427bf..d76eb249cb23e 100644 --- a/content/9-x-y/en-US/docs/api/browser-window.md +++ b/content/9-x-y/en-US/docs/api/browser-window.md @@ -177,7 +177,7 @@ It creates a new `BrowserWindow` with native properties as set by the `options`. * `simpleFullscreen` Boolean (optional) - Use pre-Lion fullscreen on macOS. Default is `false`. * `skipTaskbar` Boolean (optional) - Whether to show the window in taskbar. Default is `false`. - * `kiosk` Boolean (optional) - The kiosk mode. Default is `false`. + * `kiosk` Boolean (optional) - Whether the window is in kiosk mode. Default is `false`. * `title` String (optional) - Default window title. Default is `"Electron"`. If the HTML tag `` is defined in the HTML file loaded by `loadURL()`, this property will be ignored. * `icon` ([NativeImage](native-image.md) | String) (optional) - The window icon. On Windows it is recommended to use `ICO` icons to get best visual effects, you can also @@ -207,7 +207,7 @@ It creates a new `BrowserWindow` with native properties as set by the `options`. * `opacity` Number (optional) - Set the initial opacity of the window, between 0.0 (fully transparent) and 1.0 (fully opaque). This is only implemented on Windows and macOS. * `darkTheme` Boolean (optional) - Forces using dark theme for the window, only works on - some GTK+3 desktop environments. Default is `false`. + some GTK desktop environments. Default is `false`. * `transparent` Boolean (optional) - Makes the window [transparent](frameless-window.md#transparent-window). Default is `false`. On Windows, does not work unless the window is frameless. * `type` String (optional) - The type of window, default is normal window. See more about @@ -803,6 +803,51 @@ A `Boolean` property that determines whether the window menu bar should hide its If the menu bar is already visible, setting this property to `true` won't hide it immediately. +#### `win.simpleFullScreen` + +A `Boolean` property that determines whether the window is in simple (pre-Lion) fullscreen mode. + +#### `win.fullScreen` + +A `Boolean` property that determines whether the window is in fullscreen mode. + +#### `win.visibleOnAllWorkspaces` + +A `Boolean` property that determines whether the window is visible on all workspaces. + +**Note:** Always returns false on Windows. + +#### `win.shadow` + +A `Boolean` property that determines whether the window has a shadow. + +#### `win.menuBarVisible` _Windows_ _Linux_ + +A `Boolean` property that determines whether the menu bar should be visible. + +**Note:** If the menu bar is auto-hide, users can still bring up the menu bar by pressing the single `Alt` key. + +#### `win.kiosk` + +A `Boolean` property that determines whether the window is in kiosk mode. + +#### `win.documentEdited` _macOS_ + +A `Boolean` property that specifies whether the window’s document has been edited. + +The icon in title bar will become gray when set to `true`. + +#### `win.representedFilename` _macOS_ + +A `String` property that determines the pathname of the file the window represents, +and the icon of the file will show in window's title bar. + +#### `win.title` + +A `String` property that determines the title of the native window. + +**Note:** The title of the web page can be different from the title of the native window. + #### `win.minimizable` A `Boolean` property that determines whether the window can be manually minimized by user. @@ -958,7 +1003,7 @@ Returns `Boolean` - Whether the window is in fullscreen mode. Enters or leaves simple fullscreen mode. -Simple fullscreen mode emulates the native fullscreen behavior found in versions of Mac OS X prior to Lion (10.7). +Simple fullscreen mode emulates the native fullscreen behavior found in versions of macOS prior to Lion (10.7). #### `win.isSimpleFullScreen()` _macOS_ @@ -1282,7 +1327,7 @@ Makes the window not show in the taskbar. * `flag` Boolean -Enters or leaves the kiosk mode. +Enters or leaves kiosk mode. #### `win.isKiosk()` diff --git a/content/9-x-y/en-US/docs/api/crash-reporter.md b/content/9-x-y/en-US/docs/api/crash-reporter.md index 33464ccf2ce56..73b38782329b8 100644 --- a/content/9-x-y/en-US/docs/api/crash-reporter.md +++ b/content/9-x-y/en-US/docs/api/crash-reporter.md @@ -4,18 +4,13 @@ Process: [Main](../glossary.md#main-process), [Renderer](../glossary.md#renderer-process) -The following is an example of automatically submitting a crash report to a -remote server: +The following is an example of setting up Electron to automatically submit +crash reports to a remote server: ```javascript const { crashReporter } = require('electron') -crashReporter.start({ - productName: 'YourName', - companyName: 'YourCompany', - submitURL: 'https://your-domain.com/url-to-submit', - uploadToServer: true -}) +crashReporter.start({ submitURL: 'https://your-domain.com/url-to-submit' }) ``` For setting up a server to accept and process crash reports, you can use @@ -30,11 +25,19 @@ Or use a 3rd party hosted solution: * [Sentry](https://docs.sentry.io/clients/electron) * [BugSplat](https://www.bugsplat.com/docs/platforms/electron) -Crash reports are saved locally in an application-specific temp directory folder. -For a `productName` of `YourName`, crash reports will be stored in a folder -named `YourName Crashes` inside the temp directory. You can customize this temp -directory location for your app by calling the `app.setPath('temp', '/my/custom/temp')` -API before starting the crash reporter. +Crash reports are stored temporarily before being uploaded in a directory +underneath the app's user data directory (called 'Crashpad' on Windows and Mac, +or 'Crash Reports' on Linux). You can override this directory by calling +`app.setPath('crashDumps', '/path/to/crashes')` before starting the crash +reporter. + +On Windows and macOS, Electron uses +[crashpad](https://chromium.googlesource.com/crashpad/crashpad/+/master/README.md) +to monitor and report crashes. On Linux, Electron uses +[breakpad](https://chromium.googlesource.com/breakpad/breakpad/+/master/). This +is an implementation detail driven by Chromium, and it may change in future. In +particular, crashpad is newer and will likely eventually replace breakpad on +all platforms. ## Methods @@ -43,40 +46,68 @@ The `crashReporter` module has the following methods: ### `crashReporter.start(options)` * `options` Object - * `companyName` String * `submitURL` String - URL that crash reports will be sent to as POST. * `productName` String (optional) - Defaults to `app.name`. - * `uploadToServer` Boolean (optional) - Whether crash reports should be sent to the server. Default is `true`. - * `ignoreSystemCrashHandler` Boolean (optional) - Default is `false`. - * `extra` Record<String, String> (optional) - An object you can define that will be sent along with the - report. Only string properties are sent correctly. Nested objects are not - supported. When using Windows, the property names and values must be fewer than 64 characters. - * `crashesDirectory` String (optional) - Directory to store the crash reports temporarily (only used when the crash reporter is started via `process.crashReporter.start`). - -You are required to call this method before using any other `crashReporter` APIs -and in each process (main/renderer) from which you want to collect crash reports. -You can pass different options to `crashReporter.start` when calling from different processes. - -**Note** Child processes created via the `child_process` module will not have access to the Electron modules. -Therefore, to collect crash reports from them, use `process.crashReporter.start` instead. Pass the same options as above -along with an additional one called `crashesDirectory` that should point to a directory to store the crash -reports temporarily. You can test this out by calling `process.crash()` to crash the child process. - -**Note:** If you need send additional/updated `extra` parameters after your -first call `start` you can call `addExtraParameter` on macOS or call `start` -again with the new/updated `extra` parameters on Linux and Windows. - -**Note:** On macOS and windows, Electron uses a new `crashpad` client for crash collection and reporting. -If you want to enable crash reporting, initializing `crashpad` from the main process using `crashReporter.start` is required -regardless of which process you want to collect crashes from. Once initialized this way, the crashpad handler collects -crashes from all processes. You still have to call `crashReporter.start` from the renderer or child process, otherwise crashes from -them will get reported without `companyName`, `productName` or any of the `extra` information. + * `companyName` String (optional) _Deprecated_ - Deprecated alias for + `{ globalExtra: { _companyName: ... } }`. + * `uploadToServer` Boolean (optional) - Whether crash reports should be sent + to the server. If false, crash reports will be collected and stored in the + crashes directory, but not uploaded. Default is `true`. + * `ignoreSystemCrashHandler` Boolean (optional) - If true, crashes generated + in the main process will not be forwarded to the system crash handler. + Default is `false`. + * `rateLimit` Boolean (optional) _macOS_ _Windows_ - If true, limit the + number of crashes uploaded to 1/hour. Default is `false`. + * `compress` Boolean (optional) _macOS_ _Windows_ - If true, crash reports + will be compressed and uploaded with `Content-Encoding: gzip`. Not all + collection servers support compressed payloads. Default is `false`. + * `extra` Record<String, String> (optional) - Extra string key/value + annotations that will be sent along with crash reports that are generated + in the main process. Only string values are supported. Crashes generated in + child processes will not contain these extra + parameters to crash reports generated from child processes, call + [`addExtraParameter`](#crashreporteraddextraparameterkey-value) from the + child process. + * `globalExtra` Record<String, String> (optional) - Extra string key/value + annotations that will be sent along with any crash reports generated in any + process. These annotations cannot be changed once the crash reporter has + been started. If a key is present in both the global extra parameters and + the process-specific extra parameters, then the global one will take + precedence. By default, `productName` and the app version are included, as + well as the Electron version. + +This method must be called before using any other `crashReporter` APIs. Once +initialized this way, the crashpad handler collects crashes from all +subsequently created processes. The crash reporter cannot be disabled once +started. + +This method should be called as early as possible in app startup, preferably +before `app.on('ready')`. If the crash reporter is not initialized at the time +a renderer process is created, then that renderer process will not be monitored +by the crash reporter. + +**Note:** You can test out the crash reporter by generating a crash using +`process.crash()`. + +**Note:** If you need to send additional/updated `extra` parameters after your +first call `start` you can call `addExtraParameter`. + +**Note:** Parameters passed in `extra`, `globalExtra` or set with +`addExtraParameter` have limits on the length of the keys and values. Key names +must be at most 39 bytes long, and values must be no longer than 127 bytes. +Keys with names longer than the maximum will be silently ignored. Key values +longer than the maximum length will be truncated. + +**Note:** Calling this method from the renderer process is deprecated. ### `crashReporter.getLastCrashReport()` -Returns [`CrashReport`](structures/crash-report.md): +Returns [`CrashReport`](structures/crash-report.md) - The date and ID of the +last crash report. Only crash reports that have been uploaded will be returned; +even if a crash report is present on disk it will not be returned until it is +uploaded. In the case that there are no uploaded reports, `null` is returned. -Returns the date and ID of the last crash report. Only crash reports that have been uploaded will be returned; even if a crash report is present on disk it will not be returned until it is uploaded. In the case that there are no uploaded reports, `null` is returned. +**Note:** Calling this method from the renderer process is deprecated. ### `crashReporter.getUploadedReports()` @@ -85,43 +116,61 @@ Returns [`CrashReport[]`](structures/crash-report.md): Returns all uploaded crash reports. Each report contains the date and uploaded ID. +**Note:** Calling this method from the renderer process is deprecated. + ### `crashReporter.getUploadToServer()` Returns `Boolean` - Whether reports should be submitted to the server. Set through the `start` method or `setUploadToServer`. -**Note:** This API can only be called from the main process. +**Note:** Calling this method from the renderer process is deprecated. ### `crashReporter.setUploadToServer(uploadToServer)` -* `uploadToServer` Boolean _macOS_ - Whether reports should be submitted to the server. +* `uploadToServer` Boolean - Whether reports should be submitted to the server. This would normally be controlled by user preferences. This has no effect if called before `start` is called. -**Note:** This API can only be called from the main process. +**Note:** Calling this method from the renderer process is deprecated. -### `crashReporter.addExtraParameter(key, value)` _macOS_ _Windows_ +### `crashReporter.getCrashesDirectory()` _Deprecated_ -* `key` String - Parameter key, must be less than 64 characters long. -* `value` String - Parameter value, must be less than 64 characters long. +Returns `String` - The directory where crashes are temporarily stored before being uploaded. -Set an extra parameter to be sent with the crash report. The values -specified here will be sent in addition to any values set via the `extra` option when `start` was called. This API is only available on macOS and windows, if you need to add/update extra parameters on Linux after your first call to `start` you can call `start` again with the updated `extra` options. +**Note:** This method is deprecated, use `app.getPath('crashDumps')` instead. -### `crashReporter.removeExtraParameter(key)` _macOS_ _Windows_ +### `crashReporter.addExtraParameter(key, value)` -* `key` String - Parameter key, must be less than 64 characters long. +* `key` String - Parameter key, must be no longer than 39 bytes. +* `value` String - Parameter value, must be no longer than 127 bytes. -Remove a extra parameter from the current set of parameters so that it will not be sent with the crash report. +Set an extra parameter to be sent with the crash report. The values specified +here will be sent in addition to any values set via the `extra` option when +`start` was called. -### `crashReporter.getParameters()` +Parameters added in this fashion (or via the `extra` parameter to +`crashReporter.start`) are specific to the calling process. Adding extra +parameters in the main process will not cause those parameters to be sent along +with crashes from renderer or other child processes. Similarly, adding extra +parameters in a renderer process will not result in those parameters being sent +with crashes that occur in other renderer processes or in the main process. -See all of the current parameters being passed to the crash reporter. +**Note:** Parameters have limits on the length of the keys and values. Key +names must be no longer than 39 bytes, and values must be no longer than 127 +bytes. Keys with names longer than the maximum will be silently ignored. Key +values longer than the maximum length will be truncated. -### `crashReporter.getCrashesDirectory()` +### `crashReporter.removeExtraParameter(key)` -Returns `String` - The directory where crashes are temporarily stored before being uploaded. +* `key` String - Parameter key, must be no longer than 39 bytes. + +Remove a extra parameter from the current set of parameters. Future crashes +will not include this parameter. + +### `crashReporter.getParameters()` + +Returns `Record<String, String>` - The current 'extra' parameters of the crash reporter. ## Crash Report Payload diff --git a/content/9-x-y/en-US/docs/api/environment-variables.md b/content/9-x-y/en-US/docs/api/environment-variables.md index 016463a045b47..9e8e8d63a79bc 100644 --- a/content/9-x-y/en-US/docs/api/environment-variables.md +++ b/content/9-x-y/en-US/docs/api/environment-variables.md @@ -135,3 +135,14 @@ the one downloaded by `npm install`. Usage: ```sh export ELECTRON_OVERRIDE_DIST_PATH=/Users/username/projects/electron/out/Testing ``` + +## Set By Electron + +Electron sets some variables in your environment at runtime. + +### `ORIGINAL_XDG_CURRENT_DESKTOP` + +This variable is set to the value of `XDG_CURRENT_DESKTOP` that your application +originally launched with. Electron sometimes modifies the value of `XDG_CURRENT_DESKTOP` +to affect other logic within Chromium so if you want access to the _original_ value +you should look up this environment variable instead. diff --git a/content/current/ar-SA/docs/api/extensions.md b/content/9-x-y/en-US/docs/api/extensions.md similarity index 62% rename from content/current/ar-SA/docs/api/extensions.md rename to content/9-x-y/en-US/docs/api/extensions.md index 38fd90183978d..67837b391f19b 100644 --- a/content/current/ar-SA/docs/api/extensions.md +++ b/content/9-x-y/en-US/docs/api/extensions.md @@ -1,12 +1,21 @@ # Chrome Extension Support -Electron supports a subset of the [Chrome Extensions API](https://developer.chrome.com/extensions/api_index), primarily to support DevTools extensions and Chromium-internal extensions, but it also happens to support some other extension capabilities. +Electron supports a subset of the [Chrome Extensions +API][chrome-extensions-api-index], primarily to support DevTools extensions and +Chromium-internal extensions, but it also happens to support some other +extension capabilities. -> **Note:** Electron does not support arbitrary Chrome extensions from the store, and it is a **non-goal** of the Electron project to be perfectly compatible with Chrome's implementation of Extensions. +[chrome-extensions-api-index]: https://developer.chrome.com/extensions/api_index + +> **Note:** Electron does not support arbitrary Chrome extensions from the +> store, and it is a **non-goal** of the Electron project to be perfectly +> compatible with Chrome's implementation of Extensions. ## Loading extensions -Electron only supports loading unpacked extensions (i.e., `.crx` files do not work). Extensions are installed per-`session`. To load an extension, call [`ses.loadExtension`](session.md#sesloadextensionpath): +Electron only supports loading unpacked extensions (i.e., `.crx` files do not +work). Extensions are installed per-`session`. To load an extension, call +[`ses.loadExtension`](session.md#sesloadextensionpath): ```js const { session } = require('electron') @@ -16,15 +25,17 @@ session.loadExtension('path/to/unpacked/extension').then(({ id }) => { }) ``` -Loaded extensions will not be automatically remembered across exits; if you do not call `loadExtension` when the app runs, the extension will not be loaded. - -Note that loading extensions is only supported in persistent sessions. Attempting to load an extension into an in-memory session will throw an error. +Loaded extensions will not be automatically remembered across exits; if you do +not call `loadExtension` when the app runs, the extension will not be loaded. -See the [`session`](session.md) documentation for more information about loading, unloading, and querying active extensions. +See the [`session`](session.md) documentation for more information about +loading, unloading, and querying active extensions. ## Supported Extensions APIs -We support the following extensions APIs, with some caveats. Other APIs may additionally be supported, but support for any APIs not listed here is provisional and may be removed. +We support the following extensions APIs, with some caveats. Other APIs may +additionally be supported, but support for any APIs not listed here is +provisional and may be removed. ### `chrome.devtools.inspectedWindow` @@ -75,7 +86,8 @@ The following events of `chrome.runtime` are supported: ### `chrome.storage` -Only `chrome.storage.local` is supported; `chrome.storage.sync` and `chrome.storage.managed` are not. +Only `chrome.storage.local` is supported; `chrome.storage.sync` and +`chrome.storage.managed` are not. ### `chrome.tabs` @@ -84,4 +96,6 @@ The following methods of `chrome.tabs` are supported: - `chrome.tabs.sendMessage` - `chrome.tabs.executeScript` -> **Note:** In Chrome, passing `-1` as a tab ID signifies the "currently active tab". Since Electron has no such concept, passing `-1` as a tab ID is not supported and will raise an error. +> **Note:** In Chrome, passing `-1` as a tab ID signifies the "currently active +> tab". Since Electron has no such concept, passing `-1` as a tab ID is not +> supported and will raise an error. diff --git a/content/9-x-y/en-US/docs/api/frameless-window.md b/content/9-x-y/en-US/docs/api/frameless-window.md index fd5ff554de04e..bff1260b813f9 100644 --- a/content/9-x-y/en-US/docs/api/frameless-window.md +++ b/content/9-x-y/en-US/docs/api/frameless-window.md @@ -52,7 +52,7 @@ win.show() Uses custom drawn close, and miniaturize buttons that display when hovering in the top left of the window. The fullscreen button is not available due to restrictions of frameless windows as they -interface with Apple's MacOS window masks. These custom buttons prevent +interface with Apple's macOS window masks. These custom buttons prevent issues with mouse events that occur with the standard window toolbar buttons. This option is only applicable for frameless windows. @@ -158,7 +158,7 @@ buttons in titlebar non-draggable. ## Text selection -In a frameless window the dragging behaviour may conflict with selecting text. +In a frameless window the dragging behavior may conflict with selecting text. For example, when you drag the titlebar you may accidentally select the text on the titlebar. To prevent this, you need to disable text selection within a draggable area like this: diff --git a/content/9-x-y/en-US/docs/api/menu-item.md b/content/9-x-y/en-US/docs/api/menu-item.md index 58bb34c44103d..e65ed2e1feb73 100644 --- a/content/9-x-y/en-US/docs/api/menu-item.md +++ b/content/9-x-y/en-US/docs/api/menu-item.md @@ -14,7 +14,7 @@ See [`Menu`](menu.md) for examples. * `menuItem` MenuItem * `browserWindow` [BrowserWindow](browser-window.md) * `event` [KeyboardEvent](structures/keyboard-event.md) - * `role` String (optional) - Can be `undo`, `redo`, `cut`, `copy`, `paste`, `pasteAndMatchStyle`, `delete`, `selectAll`, `reload`, `forceReload`, `toggleDevTools`, `resetZoom`, `zoomIn`, `zoomOut`, `togglefullscreen`, `window`, `minimize`, `close`, `help`, `about`, `services`, `hide`, `hideOthers`, `unhide`, `quit`, `startSpeaking`, `stopSpeaking`, `minimize`, `zoom`, `front`, `appMenu`, `fileMenu`, `editMenu`, `viewMenu`, `recentDocuments`, `toggleTabBar`, `selectNextTab`, `selectPreviousTab`, `mergeAllWindows`, `clearRecentDocuments`, `moveTabToNewWindow` or `windowMenu` - Define the action of the menu item, when specified the + * `role` String (optional) - Can be `undo`, `redo`, `cut`, `copy`, `paste`, `pasteAndMatchStyle`, `delete`, `selectAll`, `reload`, `forceReload`, `toggleDevTools`, `resetZoom`, `zoomIn`, `zoomOut`, `togglefullscreen`, `window`, `minimize`, `close`, `help`, `about`, `services`, `hide`, `hideOthers`, `unhide`, `quit`, `startSpeaking`, `stopSpeaking`, `zoom`, `front`, `appMenu`, `fileMenu`, `editMenu`, `viewMenu`, `recentDocuments`, `toggleTabBar`, `selectNextTab`, `selectPreviousTab`, `mergeAllWindows`, `clearRecentDocuments`, `moveTabToNewWindow` or `windowMenu` - Define the action of the menu item, when specified the `click` property will be ignored. See [roles](#roles). * `type` String (optional) - Can be `normal`, `separator`, `submenu`, `checkbox` or `radio`. @@ -117,7 +117,7 @@ When specifying a `role` on macOS, `label` and `accelerator` are the only options that will affect the menu item. All other options will be ignored. Lowercase `role`, e.g. `toggledevtools`, is still supported. -**Nota Bene:** The `enabled` and `visibility` properties are not available for top-level menu items in the tray on MacOS. +**Nota Bene:** The `enabled` and `visibility` properties are not available for top-level menu items in the tray on macOS. ### Instance Properties @@ -151,7 +151,7 @@ A `String` indicating the type of the item. Can be `normal`, `separator`, `subme #### `menuItem.role` -A `String` (optional) indicating the item's role, if set. Can be `undo`, `redo`, `cut`, `copy`, `paste`, `pasteAndMatchStyle`, `delete`, `selectAll`, `reload`, `forceReload`, `toggleDevTools`, `resetZoom`, `zoomIn`, `zoomOut`, `togglefullscreen`, `window`, `minimize`, `close`, `help`, `about`, `services`, `hide`, `hideOthers`, `unhide`, `quit`, `startSpeaking`, `stopSpeaking`, `close`, `minimize`, `zoom`, `front`, `appMenu`, `fileMenu`, `editMenu`, `viewMenu`, `recentDocuments`, `toggleTabBar`, `selectNextTab`, `selectPreviousTab`, `mergeAllWindows`, `clearRecentDocuments`, `moveTabToNewWindow` or `windowMenu` +A `String` (optional) indicating the item's role, if set. Can be `undo`, `redo`, `cut`, `copy`, `paste`, `pasteAndMatchStyle`, `delete`, `selectAll`, `reload`, `forceReload`, `toggleDevTools`, `resetZoom`, `zoomIn`, `zoomOut`, `togglefullscreen`, `window`, `minimize`, `close`, `help`, `about`, `services`, `hide`, `hideOthers`, `unhide`, `quit`, `startSpeaking`, `stopSpeaking`, `zoom`, `front`, `appMenu`, `fileMenu`, `editMenu`, `viewMenu`, `recentDocuments`, `toggleTabBar`, `selectNextTab`, `selectPreviousTab`, `mergeAllWindows`, `clearRecentDocuments`, `moveTabToNewWindow` or `windowMenu` #### `menuItem.accelerator` diff --git a/content/9-x-y/en-US/docs/api/modernization/property-updates.md b/content/9-x-y/en-US/docs/api/modernization/property-updates.md index 2136e6de13ebf..7019982b6d595 100644 --- a/content/9-x-y/en-US/docs/api/modernization/property-updates.md +++ b/content/9-x-y/en-US/docs/api/modernization/property-updates.md @@ -5,14 +5,7 @@ The Electron team is currently undergoing an initiative to convert separate gett ## Candidates * `BrowserWindow` - * `fullscreen` - * `simpleFullscreen` - * `alwaysOnTop` - * `title` - * `documentEdited` - * `hasShadow` * `menubarVisible` - * `visibleOnAllWorkspaces` * `crashReporter` module * `uploadToServer` * `webFrame` modules diff --git a/content/9-x-y/en-US/docs/api/sandbox-option.md b/content/9-x-y/en-US/docs/api/sandbox-option.md index 414a308da6da0..8e856f73392c8 100644 --- a/content/9-x-y/en-US/docs/api/sandbox-option.md +++ b/content/9-x-y/en-US/docs/api/sandbox-option.md @@ -51,7 +51,7 @@ app.whenReady().then(() => { In the above code the [`BrowserWindow`](browser-window.md) that was created has Node.js disabled and can communicate only via IPC. The use of this option stops Electron from creating a Node.js runtime in the renderer. Also, -within this new window `window.open` follows the native behaviour (by default Electron creates a [`BrowserWindow`](browser-window.md) +within this new window `window.open` follows the native behavior (by default Electron creates a [`BrowserWindow`](browser-window.md) and returns a proxy to this via `window.open`). [`app.enableSandbox`](app.md#appenablesandbox-experimental) can be used to force `sandbox: true` for all `BrowserWindow` instances. diff --git a/content/9-x-y/en-US/docs/api/structures/new-window-event.md b/content/9-x-y/en-US/docs/api/structures/new-window-event.md new file mode 100644 index 0000000000000..b3939a00785a1 --- /dev/null +++ b/content/9-x-y/en-US/docs/api/structures/new-window-event.md @@ -0,0 +1,4 @@ +# NewWindowEvent Object extends `Event` + +* `newGuest` BrowserWindow (optional) + diff --git a/content/9-x-y/en-US/docs/api/system-preferences.md b/content/9-x-y/en-US/docs/api/system-preferences.md index 64b446cbea638..e18edc930798d 100644 --- a/content/9-x-y/en-US/docs/api/system-preferences.md +++ b/content/9-x-y/en-US/docs/api/system-preferences.md @@ -326,7 +326,7 @@ This API is only available on macOS 10.14 Mojave or newer. * `window-frame-text` - The text in the window's titlebar area. Returns `String` - The system color setting in RGB hexadecimal form (`#ABCDEF`). -See the [Windows docs][windows-colors] and the [MacOS docs][macos-colors] for more details. +See the [Windows docs][windows-colors] and the [macOS docs][macos-colors] for more details. The following colors are only available on macOS 10.14: `find-highlight`, `selected-content-background`, `separator`, `unemphasized-selected-content-background`, `unemphasized-selected-text-background`, and `unemphasized-selected-text`. diff --git a/content/9-x-y/en-US/docs/api/web-contents.md b/content/9-x-y/en-US/docs/api/web-contents.md index 7fb023638b081..2dcbdacfbb97b 100644 --- a/content/9-x-y/en-US/docs/api/web-contents.md +++ b/content/9-x-y/en-US/docs/api/web-contents.md @@ -138,7 +138,7 @@ Emitted when page receives favicon urls. Returns: -* `event` Event +* `event` NewWindowEvent * `url` String * `frameName` String * `disposition` String - Can be `default`, `foreground-tab`, `background-tab`, diff --git a/content/9-x-y/en-US/docs/breaking-changes.md b/content/9-x-y/en-US/docs/breaking-changes.md index 73e64ef35046a..6f36ce64f8390 100644 --- a/content/9-x-y/en-US/docs/breaking-changes.md +++ b/content/9-x-y/en-US/docs/breaking-changes.md @@ -2,13 +2,124 @@ Breaking changes will be documented here, and deprecation warnings added to JS code where possible, at least [one major version](tutorial/electron-versioning.md#semver) before the change is made. -## `FIXME` comments +### Types of Breaking Changes -The `FIXME` string is used in code comments to denote things that should be fixed for future releases. See https://github.com/electron/electron/search?q=fixme +This document uses the following convention to categorize breaking changes: + +- **API Changed:** An API was changed in such a way that code that has not been updated is guaranteed to throw an exception. +- **Behavior Changed:** The behavior of Electron has changed, but not in such a way that an exception will necessarily be thrown. +- **Default Changed:** Code depending on the old default may break, not necessarily throwing an exception. The old behavior can be restored by explicitly specifying the value. +- **Deprecated:** An API was marked as deprecated. The API will continue to function, but will emit a deprecation warning, and will be removed in a future release. +- **Removed:** An API or feature was removed, and is no longer supported by Electron. + +## Planned Breaking API Changes (12.0) + +### Removed: `crashReporter` methods in the renderer process + +The following `crashReporter` methods are no longer available in the renderer +process: + +- `crashReporter.start` +- `crashReporter.getLastCrashReport` +- `crashReporter.getUploadedReports` +- `crashReporter.getUploadToServer` +- `crashReporter.setUploadToServer` +- `crashReporter.getCrashesDirectory` + +They should be called only from the main process. + +See [#23265](https://github.com/electron/electron/pull/23265) for more details. + +## Planned Breaking API Changes (11.0) + +## Planned Breaking API Changes (10.0) + +### Deprecated: `companyName` argument to `crashReporter.start()` + +The `companyName` argument to `crashReporter.start()`, which was previously +required, is now optional, and further, is deprecated. To get the same +behavior in a non-deprecated way, you can pass a `companyName` value in +`globalExtra`. + +```js +// Deprecated in Electron 10 +crashReporter.start({ companyName: 'Umbrella Corporation' }) +// Replace with +crashReporter.start({ globalExtra: { _companyName: 'Umbrella Corporation' } }) +``` + +### Deprecated: `crashReporter.getCrashesDirectory()` + +The `crashReporter.getCrashesDirectory` method has been deprecated. Usage +should be replaced by `app.getPath('crashDumps')`. + +```js +// Deprecated in Electron 10 +crashReporter.getCrashesDirectory() +// Replace with +app.getPath('crashDumps') +``` + +### Deprecated: `crashReporter` methods in the renderer process + +Calling the following `crashReporter` methods from the renderer process is +deprecated: + +- `crashReporter.start` +- `crashReporter.getLastCrashReport` +- `crashReporter.getUploadedReports` +- `crashReporter.getUploadToServer` +- `crashReporter.setUploadToServer` +- `crashReporter.getCrashesDirectory` + +The only non-deprecated methods remaining in the `crashReporter` module in the +renderer are `addExtraParameter`, `removeExtraParameter` and `getParameters`. + +All above methods remain non-deprecated when called from the main process. + +See [#23265](https://github.com/electron/electron/pull/23265) for more details. + +### Removed: Browser Window Affinity + +The `affinity` option when constructing a new `BrowserWindow` will be removed +as part of our plan to more closely align with Chromium's process model for security, +performance and maintainability. + +For more detailed information see [#18397](https://github.com/electron/electron/issues/18397). + +### Default Changed: `enableRemoteModule` defaults to `false` + +In Electron 9, using the remote module without explicitly enabling it via the +`enableRemoteModule` WebPreferences option began emitting a warning. In +Electron 10, the remote module is now disabled by default. To use the remote +module, `enableRemoteModule: true` must be specified in WebPreferences: + +```js +const w = new BrowserWindow({ + webPreferences: { + enableRemoteModule: true + } +}) +``` + +We [recommend moving away from the remote +module](https://medium.com/@nornagon/electrons-remote-module-considered-harmful-70d69500f31). ## Planned Breaking API Changes (9.0) -### `<webview>.getWebContents()` +### Default Changed: Loading non-context-aware native modules in the renderer process is disabled by default + +As of Electron 9 we do not allow loading of non-context-aware native modules in +the renderer process. This is to improve security, performance and maintainability +of Electron as a project. + +If this impacts you, you can temporarily set `app.allowRendererProcessReuse` to `false` +to revert to the old behavior. This flag will only be an option until Electron 11 so +you should plan to update your native modules to be context aware. + +For more detailed information see [#18397](https://github.com/electron/electron/issues/18397). + +### Removed: `<webview>.getWebContents()` This API, which was deprecated in Electron 8.0, is now removed. @@ -20,7 +131,7 @@ const { remote } = require('electron') remote.webContents.fromId(webview.getWebContentsId()) ``` -### `webFrame.setLayoutZoomLevelLimits()` +### Removed: `webFrame.setLayoutZoomLevelLimits()` Chromium has removed support for changing the layout zoom level limits, and it is beyond Electron's capacity to maintain it. The function was deprecated in @@ -28,7 +139,7 @@ Electron 8.x, and has been removed in Electron 9.x. The layout zoom level limits are now fixed at a minimum of 0.25 and a maximum of 5.0, as defined [here](https://chromium.googlesource.com/chromium/src/+/938b37a6d2886bf8335fc7db792f1eb46c65b2ae/third_party/blink/common/page/page_zoom.cc#11). -### Sending non-JS objects over IPC now throws an exception +### Behavior Changed: Sending non-JS objects over IPC now throws an exception In Electron 8.0, IPC was changed to use the Structured Clone Algorithm, bringing significant performance improvements. To help ease the transition, the @@ -44,9 +155,14 @@ In Electron 9.0, the old serialization algorithm has been removed, and sending such non-serializable objects will now throw an "object could not be cloned" error. +### API Changed: `shell.openItem` is now `shell.openPath` + +The `shell.openItem` API has been replaced with an asynchronous `shell.openPath` API. +You can see the original API proposal and reasoning [here](https://github.com/electron/governance/blob/master/wg-api/spec-documents/shell-openitem.md). + ## Planned Breaking API Changes (8.0) -### Values sent over IPC are now serialized with Structured Clone Algorithm +### Behavior Changed: Values sent over IPC are now serialized with Structured Clone Algorithm The algorithm used to serialize objects sent over IPC (through `ipcRenderer.send`, `ipcRenderer.sendSync`, `WebContents.send` and related @@ -97,7 +213,7 @@ these kinds of objects will throw a 'could not be cloned' error. [SCA]: https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API/Structured_clone_algorithm -### `<webview>.getWebContents()` +### Deprecated: `<webview>.getWebContents()` This API is implemented using the `remote` module, which has both performance and security implications. Therefore its usage should be explicit. @@ -138,7 +254,7 @@ const { ipcRenderer } = require('electron') ipcRenderer.invoke('openDevTools', webview.getWebContentsId()) ``` -### `webFrame.setLayoutZoomLevelLimits()` +### Deprecated: `webFrame.setLayoutZoomLevelLimits()` Chromium has removed support for changing the layout zoom level limits, and it is beyond Electron's capacity to maintain it. The function will emit a warning @@ -148,7 +264,7 @@ limits are now fixed at a minimum of 0.25 and a maximum of 5.0, as defined ## Planned Breaking API Changes (7.0) -### Node Headers URL +### Deprecated: Atom.io Node Headers URL This is the URL specified as `disturl` in a `.npmrc` file or as the `--dist-url` command line flag when building native Node modules. Both will be supported for @@ -158,7 +274,7 @@ Deprecated: https://atom.io/download/electron Replace with: https://electronjs.org/headers -### `session.clearAuthCache(options)` +### API Changed: `session.clearAuthCache()` no longer accepts options The `session.clearAuthCache` API no longer accepts options for what to clear, and instead unconditionally clears the whole cache. @@ -169,25 +285,25 @@ session.clearAuthCache({ type: 'password' }) session.clearAuthCache() ``` -### `powerMonitor.querySystemIdleState` +### API Changed: `powerMonitor.querySystemIdleState` is now `powerMonitor.getSystemIdleState` ```js // Removed in Electron 7.0 powerMonitor.querySystemIdleState(threshold, callback) // Replace with synchronous API -const idleState = getSystemIdleState(threshold) +const idleState = powerMonitor.getSystemIdleState(threshold) ``` -### `powerMonitor.querySystemIdleTime` +### API Changed: `powerMonitor.querySystemIdleTime` is now `powerMonitor.getSystemIdleState` ```js // Removed in Electron 7.0 powerMonitor.querySystemIdleTime(callback) // Replace with synchronous API -const idleTime = getSystemIdleTime() +const idleTime = powerMonitor.getSystemIdleTime() ``` -### webFrame Isolated World APIs +### API Changed: `webFrame.setIsolatedWorldInfo` replaces separate methods ```js // Removed in Electron 7.0 @@ -204,11 +320,11 @@ webFrame.setIsolatedWorldInfo( }) ``` -### Removal of deprecated `marked` property on getBlinkMemoryInfo +### Removed: `marked` property on `getBlinkMemoryInfo` This property was removed in Chromium 77, and as such is no longer available. -### `webkitdirectory` attribute for `<input type="file"/>` +### Behavior Changed: `webkitdirectory` attribute for `<input type="file"/>` now lists directory contents The `webkitdirectory` property on HTML file inputs allows them to select folders. Previous versions of Electron had an incorrect implementation where the `event.target.files` @@ -241,9 +357,10 @@ In Electron 7, this now returns a `FileList` with a `File` object for: Note that `webkitdirectory` no longer exposes the path to the selected folder. If you require the path to the selected folder rather than the folder contents, see the `dialog.showOpenDialog` API ([link](https://github.com/electron/electron/blob/master/docs/api/dialog.md#dialogshowopendialogbrowserwindow-options)). + ## Planned Breaking API Changes (6.0) -### `win.setMenu(null)` +### API Changed: `win.setMenu(null)` is now `win.removeMenu()` ```js // Deprecated @@ -252,7 +369,7 @@ win.setMenu(null) win.removeMenu() ``` -### `contentTracing.getTraceBufferUsage()` +### API Changed: `contentTracing.getTraceBufferUsage()` is now a promise ```js // Deprecated @@ -265,7 +382,7 @@ contentTracing.getTraceBufferUsage().then(infoObject => { }) ``` -### `electron.screen` in renderer process +### API Changed: `electron.screen` in the renderer process should be accessed via `remote` ```js // Deprecated @@ -274,7 +391,7 @@ require('electron').screen require('electron').remote.screen ``` -### `require` in sandboxed renderers +### API Changed: `require()`ing node builtins in sandboxed renderers no longer implicitly loads the `remote` version ```js // Deprecated @@ -298,25 +415,25 @@ require('path') require('electron').remote.require('path') ``` -### `powerMonitor.querySystemIdleState` +### Deprecated: `powerMonitor.querySystemIdleState` replaced with `powerMonitor.getSystemIdleState` ```js // Deprecated powerMonitor.querySystemIdleState(threshold, callback) // Replace with synchronous API -const idleState = getSystemIdleState(threshold) +const idleState = powerMonitor.getSystemIdleState(threshold) ``` -### `powerMonitor.querySystemIdleTime` +### Deprecated: `powerMonitor.querySystemIdleTime` replaced with `powerMonitor.getSystemIdleTime` ```js // Deprecated powerMonitor.querySystemIdleTime(callback) // Replace with synchronous API -const idleTime = getSystemIdleTime() +const idleTime = powerMonitor.getSystemIdleTime() ``` -### `app.enableMixedSandbox` +### Deprecated: `app.enableMixedSandbox()` is no longer needed ```js // Deprecated @@ -325,7 +442,7 @@ app.enableMixedSandbox() Mixed-sandbox mode is now enabled by default. -### `Tray` +### Deprecated: `Tray.setHighlightMode` Under macOS Catalina our former Tray implementation breaks. Apple's native substitute doesn't support changing the highlighting behavior. @@ -338,7 +455,7 @@ tray.setHighlightMode(mode) ## Planned Breaking API Changes (5.0) -### `new BrowserWindow({ webPreferences })` +### Default Changed: `nodeIntegration` and `webviewTag` default to false, `contextIsolation` defaults to true The following `webPreferences` option default values are deprecated in favor of the new defaults listed below. @@ -358,16 +475,16 @@ const w = new BrowserWindow({ }) ``` -### `nativeWindowOpen` +### Behavior Changed: `nodeIntegration` in child windows opened via `nativeWindowOpen` -Child windows opened with the `nativeWindowOpen` option will always have Node.js integration disabled, unless `nodeIntegrationInSubFrames` is `true. +Child windows opened with the `nativeWindowOpen` option will always have Node.js integration disabled, unless `nodeIntegrationInSubFrames` is `true`. -### Privileged Schemes Registration +### API Changed: Registering privileged schemes must now be done before app ready -Renderer process APIs `webFrame.setRegisterURLSchemeAsPrivileged` and `webFrame.registerURLSchemeAsBypassingCSP` as well as browser process API `protocol.registerStandardSchemes` have been removed. +Renderer process APIs `webFrame.registerURLSchemeAsPrivileged` and `webFrame.registerURLSchemeAsBypassingCSP` as well as browser process API `protocol.registerStandardSchemes` have been removed. A new API, `protocol.registerSchemesAsPrivileged` has been added and should be used for registering custom schemes with the required privileges. Custom schemes are required to be registered before app ready. -### webFrame Isolated World APIs +### Deprecated: `webFrame.setIsolatedWorld*` replaced with `webFrame.setIsolatedWorldInfo` ```js // Deprecated @@ -384,7 +501,7 @@ webFrame.setIsolatedWorldInfo( }) ``` -## `webFrame.setSpellCheckProvider` +### API Changed: `webFrame.setSpellCheckProvider` now takes an asynchronous callback The `spellCheck` callback is now asynchronous, and `autoCorrectWord` parameter has been removed. ```js // Deprecated diff --git a/content/9-x-y/en-US/docs/development/build-instructions-linux.md b/content/9-x-y/en-US/docs/development/build-instructions-linux.md index 9de19443798c0..a83436ab788ff 100644 --- a/content/9-x-y/en-US/docs/development/build-instructions-linux.md +++ b/content/9-x-y/en-US/docs/development/build-instructions-linux.md @@ -25,7 +25,7 @@ Follow the guidelines below for building Electron on Linux. Doing so permits installing Node on your own home directory as a standard user. Or try repositories such as [NodeSource](https://nodesource.com/blog/nodejs-v012-iojs-and-the-nodesource-linux-repositories). * [clang](https://clang.llvm.org/get_started.html) 3.4 or later. -* Development headers of GTK+ and libnotify. +* Development headers of GTK 3 and libnotify. On Ubuntu, install the following libraries: diff --git a/content/9-x-y/en-US/docs/development/build-instructions-macos.md b/content/9-x-y/en-US/docs/development/build-instructions-macos.md index 88912e51c041f..62720006c1dc4 100644 --- a/content/9-x-y/en-US/docs/development/build-instructions-macos.md +++ b/content/9-x-y/en-US/docs/development/build-instructions-macos.md @@ -42,7 +42,7 @@ $ pip install pyobjc If you're developing Electron and don't plan to redistribute your custom Electron build, you may skip this section. -Official Electron builds are built with [Xcode 9.4.1](http://adcdownload.apple.com/Developer_Tools/Xcode_9.4.1/Xcode_9.4.1.xip), and the MacOS 10.13 SDK. Building with a newer SDK works too, but the releases currently use the 10.13 SDK. +Official Electron builds are built with [Xcode 9.4.1](http://adcdownload.apple.com/Developer_Tools/Xcode_9.4.1/Xcode_9.4.1.xip), and the macOS 10.13 SDK. Building with a newer SDK works too, but the releases currently use the 10.13 SDK. ## Building Electron diff --git a/content/9-x-y/en-US/docs/development/debugging-instructions-macos.md b/content/9-x-y/en-US/docs/development/debugging-instructions-macos.md index fcdc33820f284..2a2631800b066 100644 --- a/content/9-x-y/en-US/docs/development/debugging-instructions-macos.md +++ b/content/9-x-y/en-US/docs/development/debugging-instructions-macos.md @@ -20,7 +20,7 @@ you prefer a graphical interface. tail calls, and other compiler optimizations. * **Xcode**: In addition to Xcode, also install the Xcode command line tools. - They include LLDB, the default debugger in Xcode on Mac OS X. It supports + They include LLDB, the default debugger in Xcode on macOS. It supports debugging C, Objective-C and C++ on the desktop and iOS devices and simulator. * **.lldbinit**: Create or edit `~/.lldbinit` to allow Chromium code to be properly source-mapped. diff --git a/content/9-x-y/en-US/docs/development/pull-requests.md b/content/9-x-y/en-US/docs/development/pull-requests.md index 53eec082752b3..85f660c58afc9 100644 --- a/content/9-x-y/en-US/docs/development/pull-requests.md +++ b/content/9-x-y/en-US/docs/development/pull-requests.md @@ -35,7 +35,7 @@ $ git fetch upstream Build steps and dependencies differ slightly depending on your operating system. See these detailed guides on building Electron locally: -* [Building on MacOS](https://electronjs.org/docs/development/build-instructions-macos) +* [Building on macOS](https://electronjs.org/docs/development/build-instructions-macos) * [Building on Linux](https://electronjs.org/docs/development/build-instructions-linux) * [Building on Windows](https://electronjs.org/docs/development/build-instructions-windows) diff --git a/content/9-x-y/en-US/docs/tutorial/installation.md b/content/9-x-y/en-US/docs/tutorial/installation.md index 69e697a8cb975..dcdc4142cd966 100644 --- a/content/9-x-y/en-US/docs/tutorial/installation.md +++ b/content/9-x-y/en-US/docs/tutorial/installation.md @@ -76,7 +76,7 @@ that cache folder to provide custom builds of Electron or to avoid making contac with the network at all. * Linux: `$XDG_CACHE_HOME` or `~/.cache/electron/` -* MacOS: `~/Library/Caches/electron/` +* macOS: `~/Library/Caches/electron/` * Windows: `$LOCALAPPDATA/electron/Cache` or `~/AppData/Local/electron/Cache/` On environments that have been using older versions of Electron, you might find the diff --git a/content/9-x-y/en-US/docs/tutorial/macos-dock.md b/content/9-x-y/en-US/docs/tutorial/macos-dock.md index 3f4ab58333542..25b5f3f733237 100644 --- a/content/9-x-y/en-US/docs/tutorial/macos-dock.md +++ b/content/9-x-y/en-US/docs/tutorial/macos-dock.md @@ -1,4 +1,4 @@ -# MacOS Dock +# macOS Dock Electron has APIs to configure the app's icon in the macOS Dock. A macOS-only API exists to create a custom dock menu, but diff --git a/content/9-x-y/en-US/docs/tutorial/testing-widevine-cdm.md b/content/9-x-y/en-US/docs/tutorial/testing-widevine-cdm.md index 4be3025634115..b2bcd7cde4a6f 100644 --- a/content/9-x-y/en-US/docs/tutorial/testing-widevine-cdm.md +++ b/content/9-x-y/en-US/docs/tutorial/testing-widevine-cdm.md @@ -49,7 +49,7 @@ The library file `widevinecdm.dll` will be under `Program Files(x86)/Google/Chrome/Application/CHROME_VERSION/WidevineCdm/_platform_specific/win_(x86|x64)/` directory. -### On MacOS +### On macOS The library file `libwidevinecdm.dylib` will be under `/Applications/Google Chrome.app/Contents/Versions/CHROME_VERSION/Google Chrome Framework.framework/Versions/A/Libraries/WidevineCdm/_platform_specific/mac_(x86|x64)/` diff --git a/content/current/ar-SA/docs/api/message-channel-main.md b/content/current/ar-SA/docs/api/message-channel-main.md deleted file mode 100644 index 464406b39908f..0000000000000 --- a/content/current/ar-SA/docs/api/message-channel-main.md +++ /dev/null @@ -1,26 +0,0 @@ -# MessageChannelMain - -`MessageChannelMain` is the main-process-side equivalent of the DOM [`MessageChannel`][] object. Its singular function is to create a pair of connected [`MessagePortMain`](message-port-main.md) objects. - -See the [Channel Messaging API](https://developer.mozilla.org/en-US/docs/Web/API/Channel_Messaging_API) documentation for more information on using channel messaging. - -## Class: MessageChannelMain - -العملية: [Main](../glossary.md#main-process) - -مثال: -```js -const { port1, port2 } = new MessageChannelMain() -w.webContents.postMessage('port', null, [port2]) -port1.postMessage({ some: 'message' }) -``` - -### Instance Properties - -#### `channel.port1` - -A [`MessagePortMain`](message-port-main.md) property. - -#### `channel.port2` - -A [`MessagePortMain`](message-port-main.md) property. diff --git a/content/current/ar-SA/docs/api/message-port-main.md b/content/current/ar-SA/docs/api/message-port-main.md deleted file mode 100644 index d749fa4fc5e96..0000000000000 --- a/content/current/ar-SA/docs/api/message-port-main.md +++ /dev/null @@ -1,44 +0,0 @@ -# MessagePortMain - -`MessagePortMain` is the main-process-side equivalent of the DOM [`MessagePort`][] object. It behaves similarly to the DOM version, with the exception that it uses the Node.js `EventEmitter` event system, instead of the DOM `EventTarget` system. This means you should use `port.on('message', ...)` to listen for events, instead of `port.onmessage = ...` or `port.addEventListener('message', ...)` - -See the [Channel Messaging API](https://developer.mozilla.org/en-US/docs/Web/API/Channel_Messaging_API) documentation for more information on using channel messaging. - -`MessagePortMain` is an \[EventEmitter\]\[event-emitter\]. - -## Class: MessagePortMain - -العملية: [Main](../glossary.md#main-process) - -### Instance Methods - -#### `port.postMessage(message, [transfer])` - -* `message` any -* `transfer` MessagePortMain[] (optional) - -Sends a message from the port, and optionally, transfers ownership of objects to other browsing contexts. - -#### `port.start()` - -Starts the sending of messages queued on the port. Messages will be queued until this method is called. - -#### `port.close()` - -Disconnects the port, so it is no longer active. - -### Instance Events - -#### Event: 'message' - -Returns: - -* `messageEvent` Object - * `data` any - * `ports` MessagePortMain[] - -Emitted when a MessagePortMain object receives a message. - -#### Event: 'close' - -Emitted when the remote end of a MessagePortMain object becomes disconnected. diff --git a/content/current/ar-SA/docs/api/service-workers.md b/content/current/ar-SA/docs/api/service-workers.md deleted file mode 100644 index 5f5655a9453b3..0000000000000 --- a/content/current/ar-SA/docs/api/service-workers.md +++ /dev/null @@ -1,61 +0,0 @@ -## Class: ServiceWorkers - -> Query and receive events from a sessions active service workers. - -العملية: [Main](../glossary.md#main-process) - -Instances of the `ServiceWorkers` class are accessed by using `serviceWorkers` property of a `Session`. - -For example: - -```javascript -const { session } = require('electron') - -// Get all service workers. -console.log(session.defaultSession.serviceWorkers.getAllRunning()) - -// Handle logs and get service worker info -session.defaultSession.serviceWorkers.on('console-message', (event, messageDetails) => { - console.log( - 'Got service worker message', - messageDetails, - 'from', - session.defaultSession.serviceWorkers.getFromVersionID(messageDetails.versionId) - ) -}) -``` - -### Instance Events - -The following events are available on instances of `ServiceWorkers`: - -#### Event: 'console-message' - -Returns: - -* `event` Event -* `messageDetails` Object - Information about the console message - * `message` String - The actual console message - * `versionId` Number - The version ID of the service worker that sent the log message - * `source` String - The type of source for this message. Can be `javascript`, `xml`, `network`, `console-api`, `storage`, `app-cache`, `rendering`, `security`, `deprecation`, `worker`, `violation`, `intervention`, `recommendation` or `other`. - * `level` Number - The log level, from 0 to 3. In order it matches `verbose`, `info`, `warning` and `error`. - * `sourceUrl` String - The URL the message came from - * `lineNumber` Number - The line number of the source that triggered this console message - -Emitted when a service worker logs something to the console. - -### Instance Methods - -The following methods are available on instances of `ServiceWorkers`: - -#### `serviceWorkers.getAllRunning()` - -Returns `Record<Number, ServiceWorkerInfo>` - A [ServiceWorkerInfo](structures/service-worker-info.md) object where the keys are the service worker version ID and the values are the information about that service worker. - -#### `serviceWorkers.getFromVersionID(versionId)` - -* `versionId` Number - -Returns [`ServiceWorkerInfo`](structures/service-worker-info.md) - Information about this service worker - -If the service worker does not exist or is not running this method will throw an exception. diff --git a/content/current/ar-SA/docs/api/structures/extension.md b/content/current/ar-SA/docs/api/structures/extension.md deleted file mode 100644 index f99240bfe65ba..0000000000000 --- a/content/current/ar-SA/docs/api/structures/extension.md +++ /dev/null @@ -1,8 +0,0 @@ -# Extension Object - -* `id` سلسلة نصية -* `manifest` any - Copy of the [extension's manifest data](https://developer.chrome.com/extensions/manifest). -* `name` سلسلة نصية -* `path` String - The extension's file path. -* `الإصدار` String -* `url` String - The extension's `chrome-extension://` URL. diff --git a/content/current/ar-SA/docs/api/structures/post-body.md b/content/current/ar-SA/docs/api/structures/post-body.md deleted file mode 100644 index 75d01bc891e2a..0000000000000 --- a/content/current/ar-SA/docs/api/structures/post-body.md +++ /dev/null @@ -1,19 +0,0 @@ -# PostBody Object - -* `data` Array<[PostData](./post-data.md)> - The post data to be sent to the new window. -* `contentType` String - The `content-type` header used for the data. One of `application/x-www-form-urlencoded` or `multipart/form-data`. Corresponds to the `enctype` attribute of the submitted HTML form. -* `boundary` String (optional) - The boundary used to separate multiple parts of the message. Only valid when `contentType` is `multipart/form-data`. - -Note that keys starting with `--` are not currently supported. For example, this will errantly submit as `multipart/form-data` when `nativeWindowOpen` is set to `false` in webPreferences: - -```html -<form - target="_blank" - method="POST" - enctype="application/x-www-form-urlencoded" - action="https://postman-echo.com/post" -> - <input type="text" name="--theKey"> - <input type="submit"> -</form> -``` diff --git a/content/current/ar-SA/docs/api/structures/post-data.md b/content/current/ar-SA/docs/api/structures/post-data.md deleted file mode 100644 index 0b80a9957b975..0000000000000 --- a/content/current/ar-SA/docs/api/structures/post-data.md +++ /dev/null @@ -1,12 +0,0 @@ -# PostData Object - -* `type` String - One of the following: - * `rawData` - The data is available as a `Buffer`, in the `rawData` field. - * `file` - The object represents a file. The `filePath`, `offset`, `length` and `modificationTime` fields will be used to describe the file. - * `blob` - The object represents a `Blob`. The `blobUUID` field will be used to describe the `Blob`. -* `bytes` String (optional) - The raw bytes of the post data in a `Buffer`. Required for the `rawData` type. -* `filePath` String (optional) - The path of the file being uploaded. Required for the `file` type. -* `blobUUID` String (optional) - The `UUID` of the `Blob` being uploaded. Required for the `blob` type. -* `offset` Integer (optional) - The offset from the beginning of the file being uploaded, in bytes. Only valid for `file` types. -* `length` Integer (optional) - The length of the file being uploaded, in bytes. If set to `-1`, the whole file will be uploaded. Only valid for `file` types. -* `modificationTime` Double (optional) - The modification time of the file represented by a double, which is the number of seconds since the `UNIX Epoch` (Jan 1, 1970). Only valid for `file` types. diff --git a/content/current/ar-SA/docs/api/structures/service-worker-info.md b/content/current/ar-SA/docs/api/structures/service-worker-info.md deleted file mode 100644 index 578ef347744a2..0000000000000 --- a/content/current/ar-SA/docs/api/structures/service-worker-info.md +++ /dev/null @@ -1,5 +0,0 @@ -# ServiceWorkerInfo Object - -* `scriptUrl` String - The full URL to the script that this service worker runs -* `scope` String - The base URL that this service worker is active for. -* `renderProcessId` Number - The virtual ID of the process that this service worker is running in. This is not an OS level PID. This aligns with the ID set used for `webContents.getProcessId()`. diff --git a/content/current/ar-SA/docs/api/touch-bar-other-items-proxy.md b/content/current/ar-SA/docs/api/touch-bar-other-items-proxy.md deleted file mode 100644 index 5eb60d1abf211..0000000000000 --- a/content/current/ar-SA/docs/api/touch-bar-other-items-proxy.md +++ /dev/null @@ -1,9 +0,0 @@ -## Class: TouchBarOtherItemsProxy - -> Instantiates a special "other items proxy", which nests TouchBar elements inherited from Chromium at the space indicated by the proxy. By default, this proxy is added to each TouchBar at the end of the input. For more information, see the AppKit docs on [NSTouchBarItemIdentifierOtherItemsProxy](https://developer.apple.com/documentation/appkit/nstouchbaritemidentifierotheritemsproxy) -> -> Note: Only one instance of this class can be added per TouchBar. - -Process: [Main](../tutorial/application-architecture.md#main-and-renderer-processes) - -### `new TouchBarOtherItemsProxy()` diff --git a/content/current/bg-BG/docs/api/extensions.md b/content/current/bg-BG/docs/api/extensions.md deleted file mode 100644 index 38fd90183978d..0000000000000 --- a/content/current/bg-BG/docs/api/extensions.md +++ /dev/null @@ -1,87 +0,0 @@ -# Chrome Extension Support - -Electron supports a subset of the [Chrome Extensions API](https://developer.chrome.com/extensions/api_index), primarily to support DevTools extensions and Chromium-internal extensions, but it also happens to support some other extension capabilities. - -> **Note:** Electron does not support arbitrary Chrome extensions from the store, and it is a **non-goal** of the Electron project to be perfectly compatible with Chrome's implementation of Extensions. - -## Loading extensions - -Electron only supports loading unpacked extensions (i.e., `.crx` files do not work). Extensions are installed per-`session`. To load an extension, call [`ses.loadExtension`](session.md#sesloadextensionpath): - -```js -const { session } = require('electron') - -session.loadExtension('path/to/unpacked/extension').then(({ id }) => { - // ... -}) -``` - -Loaded extensions will not be automatically remembered across exits; if you do not call `loadExtension` when the app runs, the extension will not be loaded. - -Note that loading extensions is only supported in persistent sessions. Attempting to load an extension into an in-memory session will throw an error. - -See the [`session`](session.md) documentation for more information about loading, unloading, and querying active extensions. - -## Supported Extensions APIs - -We support the following extensions APIs, with some caveats. Other APIs may additionally be supported, but support for any APIs not listed here is provisional and may be removed. - -### `chrome.devtools.inspectedWindow` - -All features of this API are supported. - -### `chrome.devtools.network` - -All features of this API are supported. - -### `chrome.devtools.panels` - -All features of this API are supported. - -### `chrome.extension` - -The following properties of `chrome.extension` are supported: - -- `chrome.extension.lastError` - -The following methods of `chrome.extension` are supported: - -- `chrome.extension.getURL` -- `chrome.extension.getBackgroundPage` - -### `chrome.runtime` - -The following properties of `chrome.runtime` are supported: - -- `chrome.runtime.lastError` -- `chrome.runtime.id` - -The following methods of `chrome.runtime` are supported: - -- `chrome.runtime.getBackgroundPage` -- `chrome.runtime.getManifest` -- `chrome.runtime.getURL` -- `chrome.runtime.connect` -- `chrome.runtime.sendMessage` - -The following events of `chrome.runtime` are supported: - -- `chrome.runtime.onStartup` -- `chrome.runtime.onInstalled` -- `chrome.runtime.onSuspend` -- `chrome.runtime.onSuspendCanceled` -- `chrome.runtime.onConnect` -- `chrome.runtime.onMessage` - -### `chrome.storage` - -Only `chrome.storage.local` is supported; `chrome.storage.sync` and `chrome.storage.managed` are not. - -### `chrome.tabs` - -The following methods of `chrome.tabs` are supported: - -- `chrome.tabs.sendMessage` -- `chrome.tabs.executeScript` - -> **Note:** In Chrome, passing `-1` as a tab ID signifies the "currently active tab". Since Electron has no such concept, passing `-1` as a tab ID is not supported and will raise an error. diff --git a/content/current/bg-BG/docs/api/message-channel-main.md b/content/current/bg-BG/docs/api/message-channel-main.md deleted file mode 100644 index 3229f17dc7e24..0000000000000 --- a/content/current/bg-BG/docs/api/message-channel-main.md +++ /dev/null @@ -1,26 +0,0 @@ -# MessageChannelMain - -`MessageChannelMain` is the main-process-side equivalent of the DOM [`MessageChannel`][] object. Its singular function is to create a pair of connected [`MessagePortMain`](message-port-main.md) objects. - -See the [Channel Messaging API](https://developer.mozilla.org/en-US/docs/Web/API/Channel_Messaging_API) documentation for more information on using channel messaging. - -## Class: MessageChannelMain - -Процеса: [Main](../glossary.md#main-process) - -Пример: -```js -const { port1, port2 } = new MessageChannelMain() -w.webContents.postMessage('port', null, [port2]) -port1.postMessage({ some: 'message' }) -``` - -### Инстантни свойства - -#### `channel.port1` - -A [`MessagePortMain`](message-port-main.md) property. - -#### `channel.port2` - -A [`MessagePortMain`](message-port-main.md) property. diff --git a/content/current/bg-BG/docs/api/message-port-main.md b/content/current/bg-BG/docs/api/message-port-main.md deleted file mode 100644 index a56e13b4aef9f..0000000000000 --- a/content/current/bg-BG/docs/api/message-port-main.md +++ /dev/null @@ -1,44 +0,0 @@ -# MessagePortMain - -`MessagePortMain` is the main-process-side equivalent of the DOM [`MessagePort`][] object. It behaves similarly to the DOM version, with the exception that it uses the Node.js `EventEmitter` event system, instead of the DOM `EventTarget` system. This means you should use `port.on('message', ...)` to listen for events, instead of `port.onmessage = ...` or `port.addEventListener('message', ...)` - -See the [Channel Messaging API](https://developer.mozilla.org/en-US/docs/Web/API/Channel_Messaging_API) documentation for more information on using channel messaging. - -`MessagePortMain` is an \[EventEmitter\]\[event-emitter\]. - -## Class: MessagePortMain - -Процеса: [Main](../glossary.md#main-process) - -### Инстантни методи - -#### `port.postMessage(message, [transfer])` - -* `message` any -* `transfer` MessagePortMain[] (optional) - -Sends a message from the port, and optionally, transfers ownership of objects to other browsing contexts. - -#### `port.start()` - -Starts the sending of messages queued on the port. Messages will be queued until this method is called. - -#### `port.close()` - -Disconnects the port, so it is no longer active. - -### Събития - -#### Event: 'message' - -Връща: - -* `messageEvent` Object - * `data` any - * `ports` MessagePortMain[] - -Emitted when a MessagePortMain object receives a message. - -#### Event: 'close' - -Emitted when the remote end of a MessagePortMain object becomes disconnected. diff --git a/content/current/bg-BG/docs/api/service-workers.md b/content/current/bg-BG/docs/api/service-workers.md deleted file mode 100644 index bfe182b2e5eb8..0000000000000 --- a/content/current/bg-BG/docs/api/service-workers.md +++ /dev/null @@ -1,61 +0,0 @@ -## Class: ServiceWorkers - -> Query and receive events from a sessions active service workers. - -Процеса: [Main](../glossary.md#main-process) - -Instances of the `ServiceWorkers` class are accessed by using `serviceWorkers` property of a `Session`. - -Например: - -```javascript -const { session } = require('electron') - -// Get all service workers. -console.log(session.defaultSession.serviceWorkers.getAllRunning()) - -// Handle logs and get service worker info -session.defaultSession.serviceWorkers.on('console-message', (event, messageDetails) => { - console.log( - 'Got service worker message', - messageDetails, - 'from', - session.defaultSession.serviceWorkers.getFromVersionID(messageDetails.versionId) - ) -}) -``` - -### Събития - -The following events are available on instances of `ServiceWorkers`: - -#### Event: 'console-message' - -Връща: - -* `event` Събитие -* `messageDetails` Object - Information about the console message - * `message` String - The actual console message - * `versionId` Number - The version ID of the service worker that sent the log message - * `source` String - The type of source for this message. Can be `javascript`, `xml`, `network`, `console-api`, `storage`, `app-cache`, `rendering`, `security`, `deprecation`, `worker`, `violation`, `intervention`, `recommendation` or `other`. - * `level` Number - The log level, from 0 to 3. In order it matches `verbose`, `info`, `warning` and `error`. - * `sourceUrl` String - The URL the message came from - * `lineNumber` Number - The line number of the source that triggered this console message - -Emitted when a service worker logs something to the console. - -### Инстантни методи - -The following methods are available on instances of `ServiceWorkers`: - -#### `serviceWorkers.getAllRunning()` - -Returns `Record<Number, ServiceWorkerInfo>` - A [ServiceWorkerInfo](structures/service-worker-info.md) object where the keys are the service worker version ID and the values are the information about that service worker. - -#### `serviceWorkers.getFromVersionID(versionId)` - -* `versionId` Number - -Returns [`ServiceWorkerInfo`](structures/service-worker-info.md) - Information about this service worker - -If the service worker does not exist or is not running this method will throw an exception. diff --git a/content/current/bg-BG/docs/api/structures/extension.md b/content/current/bg-BG/docs/api/structures/extension.md deleted file mode 100644 index df9e77c202699..0000000000000 --- a/content/current/bg-BG/docs/api/structures/extension.md +++ /dev/null @@ -1,8 +0,0 @@ -# Extension Object - -* `id` String -* `manifest` any - Copy of the [extension's manifest data](https://developer.chrome.com/extensions/manifest). -* `name` String -* `path` String - The extension's file path. -* `version` String -* `url` String - The extension's `chrome-extension://` URL. diff --git a/content/current/bg-BG/docs/api/structures/post-body.md b/content/current/bg-BG/docs/api/structures/post-body.md deleted file mode 100644 index 75d01bc891e2a..0000000000000 --- a/content/current/bg-BG/docs/api/structures/post-body.md +++ /dev/null @@ -1,19 +0,0 @@ -# PostBody Object - -* `data` Array<[PostData](./post-data.md)> - The post data to be sent to the new window. -* `contentType` String - The `content-type` header used for the data. One of `application/x-www-form-urlencoded` or `multipart/form-data`. Corresponds to the `enctype` attribute of the submitted HTML form. -* `boundary` String (optional) - The boundary used to separate multiple parts of the message. Only valid when `contentType` is `multipart/form-data`. - -Note that keys starting with `--` are not currently supported. For example, this will errantly submit as `multipart/form-data` when `nativeWindowOpen` is set to `false` in webPreferences: - -```html -<form - target="_blank" - method="POST" - enctype="application/x-www-form-urlencoded" - action="https://postman-echo.com/post" -> - <input type="text" name="--theKey"> - <input type="submit"> -</form> -``` diff --git a/content/current/bg-BG/docs/api/structures/post-data.md b/content/current/bg-BG/docs/api/structures/post-data.md deleted file mode 100644 index 0b80a9957b975..0000000000000 --- a/content/current/bg-BG/docs/api/structures/post-data.md +++ /dev/null @@ -1,12 +0,0 @@ -# PostData Object - -* `type` String - One of the following: - * `rawData` - The data is available as a `Buffer`, in the `rawData` field. - * `file` - The object represents a file. The `filePath`, `offset`, `length` and `modificationTime` fields will be used to describe the file. - * `blob` - The object represents a `Blob`. The `blobUUID` field will be used to describe the `Blob`. -* `bytes` String (optional) - The raw bytes of the post data in a `Buffer`. Required for the `rawData` type. -* `filePath` String (optional) - The path of the file being uploaded. Required for the `file` type. -* `blobUUID` String (optional) - The `UUID` of the `Blob` being uploaded. Required for the `blob` type. -* `offset` Integer (optional) - The offset from the beginning of the file being uploaded, in bytes. Only valid for `file` types. -* `length` Integer (optional) - The length of the file being uploaded, in bytes. If set to `-1`, the whole file will be uploaded. Only valid for `file` types. -* `modificationTime` Double (optional) - The modification time of the file represented by a double, which is the number of seconds since the `UNIX Epoch` (Jan 1, 1970). Only valid for `file` types. diff --git a/content/current/bg-BG/docs/api/structures/service-worker-info.md b/content/current/bg-BG/docs/api/structures/service-worker-info.md deleted file mode 100644 index 578ef347744a2..0000000000000 --- a/content/current/bg-BG/docs/api/structures/service-worker-info.md +++ /dev/null @@ -1,5 +0,0 @@ -# ServiceWorkerInfo Object - -* `scriptUrl` String - The full URL to the script that this service worker runs -* `scope` String - The base URL that this service worker is active for. -* `renderProcessId` Number - The virtual ID of the process that this service worker is running in. This is not an OS level PID. This aligns with the ID set used for `webContents.getProcessId()`. diff --git a/content/current/bg-BG/docs/api/touch-bar-other-items-proxy.md b/content/current/bg-BG/docs/api/touch-bar-other-items-proxy.md deleted file mode 100644 index 5eb60d1abf211..0000000000000 --- a/content/current/bg-BG/docs/api/touch-bar-other-items-proxy.md +++ /dev/null @@ -1,9 +0,0 @@ -## Class: TouchBarOtherItemsProxy - -> Instantiates a special "other items proxy", which nests TouchBar elements inherited from Chromium at the space indicated by the proxy. By default, this proxy is added to each TouchBar at the end of the input. For more information, see the AppKit docs on [NSTouchBarItemIdentifierOtherItemsProxy](https://developer.apple.com/documentation/appkit/nstouchbaritemidentifierotheritemsproxy) -> -> Note: Only one instance of this class can be added per TouchBar. - -Process: [Main](../tutorial/application-architecture.md#main-and-renderer-processes) - -### `new TouchBarOtherItemsProxy()` diff --git a/content/current/cs-CZ/docs/api/extensions.md b/content/current/cs-CZ/docs/api/extensions.md deleted file mode 100644 index 38fd90183978d..0000000000000 --- a/content/current/cs-CZ/docs/api/extensions.md +++ /dev/null @@ -1,87 +0,0 @@ -# Chrome Extension Support - -Electron supports a subset of the [Chrome Extensions API](https://developer.chrome.com/extensions/api_index), primarily to support DevTools extensions and Chromium-internal extensions, but it also happens to support some other extension capabilities. - -> **Note:** Electron does not support arbitrary Chrome extensions from the store, and it is a **non-goal** of the Electron project to be perfectly compatible with Chrome's implementation of Extensions. - -## Loading extensions - -Electron only supports loading unpacked extensions (i.e., `.crx` files do not work). Extensions are installed per-`session`. To load an extension, call [`ses.loadExtension`](session.md#sesloadextensionpath): - -```js -const { session } = require('electron') - -session.loadExtension('path/to/unpacked/extension').then(({ id }) => { - // ... -}) -``` - -Loaded extensions will not be automatically remembered across exits; if you do not call `loadExtension` when the app runs, the extension will not be loaded. - -Note that loading extensions is only supported in persistent sessions. Attempting to load an extension into an in-memory session will throw an error. - -See the [`session`](session.md) documentation for more information about loading, unloading, and querying active extensions. - -## Supported Extensions APIs - -We support the following extensions APIs, with some caveats. Other APIs may additionally be supported, but support for any APIs not listed here is provisional and may be removed. - -### `chrome.devtools.inspectedWindow` - -All features of this API are supported. - -### `chrome.devtools.network` - -All features of this API are supported. - -### `chrome.devtools.panels` - -All features of this API are supported. - -### `chrome.extension` - -The following properties of `chrome.extension` are supported: - -- `chrome.extension.lastError` - -The following methods of `chrome.extension` are supported: - -- `chrome.extension.getURL` -- `chrome.extension.getBackgroundPage` - -### `chrome.runtime` - -The following properties of `chrome.runtime` are supported: - -- `chrome.runtime.lastError` -- `chrome.runtime.id` - -The following methods of `chrome.runtime` are supported: - -- `chrome.runtime.getBackgroundPage` -- `chrome.runtime.getManifest` -- `chrome.runtime.getURL` -- `chrome.runtime.connect` -- `chrome.runtime.sendMessage` - -The following events of `chrome.runtime` are supported: - -- `chrome.runtime.onStartup` -- `chrome.runtime.onInstalled` -- `chrome.runtime.onSuspend` -- `chrome.runtime.onSuspendCanceled` -- `chrome.runtime.onConnect` -- `chrome.runtime.onMessage` - -### `chrome.storage` - -Only `chrome.storage.local` is supported; `chrome.storage.sync` and `chrome.storage.managed` are not. - -### `chrome.tabs` - -The following methods of `chrome.tabs` are supported: - -- `chrome.tabs.sendMessage` -- `chrome.tabs.executeScript` - -> **Note:** In Chrome, passing `-1` as a tab ID signifies the "currently active tab". Since Electron has no such concept, passing `-1` as a tab ID is not supported and will raise an error. diff --git a/content/current/cs-CZ/docs/api/message-channel-main.md b/content/current/cs-CZ/docs/api/message-channel-main.md deleted file mode 100644 index 4a3b14a303994..0000000000000 --- a/content/current/cs-CZ/docs/api/message-channel-main.md +++ /dev/null @@ -1,26 +0,0 @@ -# MessageChannelMain - -`MessageChannelMain` is the main-process-side equivalent of the DOM [`MessageChannel`][] object. Its singular function is to create a pair of connected [`MessagePortMain`](message-port-main.md) objects. - -See the [Channel Messaging API](https://developer.mozilla.org/en-US/docs/Web/API/Channel_Messaging_API) documentation for more information on using channel messaging. - -## Class: MessageChannelMain - -Process: [Main](../glossary.md#main-process) - -Ukázka: -```js -const { port1, port2 } = new MessageChannelMain() -w.webContents.postMessage('port', null, [port2]) -port1.postMessage({ some: 'message' }) -``` - -### Instance Properties - -#### `channel.port1` - -A [`MessagePortMain`](message-port-main.md) property. - -#### `channel.port2` - -A [`MessagePortMain`](message-port-main.md) property. diff --git a/content/current/cs-CZ/docs/api/message-port-main.md b/content/current/cs-CZ/docs/api/message-port-main.md deleted file mode 100644 index 70393b7a852e9..0000000000000 --- a/content/current/cs-CZ/docs/api/message-port-main.md +++ /dev/null @@ -1,44 +0,0 @@ -# MessagePortMain - -`MessagePortMain` is the main-process-side equivalent of the DOM [`MessagePort`][] object. It behaves similarly to the DOM version, with the exception that it uses the Node.js `EventEmitter` event system, instead of the DOM `EventTarget` system. This means you should use `port.on('message', ...)` to listen for events, instead of `port.onmessage = ...` or `port.addEventListener('message', ...)` - -See the [Channel Messaging API](https://developer.mozilla.org/en-US/docs/Web/API/Channel_Messaging_API) documentation for more information on using channel messaging. - -`MessagePortMain` is an \[EventEmitter\]\[event-emitter\]. - -## Class: MessagePortMain - -Process: [Main](../glossary.md#main-process) - -### Instance Methods - -#### `port.postMessage(message, [transfer])` - -* `message` any -* `transfer` MessagePortMain[] (optional) - -Sends a message from the port, and optionally, transfers ownership of objects to other browsing contexts. - -#### `port.start()` - -Starts the sending of messages queued on the port. Messages will be queued until this method is called. - -#### `port.close()` - -Disconnects the port, so it is no longer active. - -### Instance Events - -#### Event: 'message' - -Vrací: - -* `messageEvent` Object - * `data` any - * `ports` MessagePortMain[] - -Emitted when a MessagePortMain object receives a message. - -#### Event: 'close' - -Emitted when the remote end of a MessagePortMain object becomes disconnected. diff --git a/content/current/cs-CZ/docs/api/service-workers.md b/content/current/cs-CZ/docs/api/service-workers.md deleted file mode 100644 index 9324d847db939..0000000000000 --- a/content/current/cs-CZ/docs/api/service-workers.md +++ /dev/null @@ -1,61 +0,0 @@ -## Class: ServiceWorkers - -> Query and receive events from a sessions active service workers. - -Process: [Main](../glossary.md#main-process) - -Instances of the `ServiceWorkers` class are accessed by using `serviceWorkers` property of a `Session`. - -Například: - -```javascript -const { session } = require('electron') - -// Get all service workers. -console.log(session.defaultSession.serviceWorkers.getAllRunning()) - -// Handle logs and get service worker info -session.defaultSession.serviceWorkers.on('console-message', (event, messageDetails) => { - console.log( - 'Got service worker message', - messageDetails, - 'from', - session.defaultSession.serviceWorkers.getFromVersionID(messageDetails.versionId) - ) -}) -``` - -### Instance Events - -The following events are available on instances of `ServiceWorkers`: - -#### Event: 'console-message' - -Vrací: - -* `event` Event -* `messageDetails` Object - Information about the console message - * `message` String - The actual console message - * `versionId` Number - The version ID of the service worker that sent the log message - * `source` String - The type of source for this message. Can be `javascript`, `xml`, `network`, `console-api`, `storage`, `app-cache`, `rendering`, `security`, `deprecation`, `worker`, `violation`, `intervention`, `recommendation` or `other`. - * `level` Number - The log level, from 0 to 3. In order it matches `verbose`, `info`, `warning` and `error`. - * `sourceUrl` String - The URL the message came from - * `lineNumber` Number - The line number of the source that triggered this console message - -Emitted when a service worker logs something to the console. - -### Instance Methods - -The following methods are available on instances of `ServiceWorkers`: - -#### `serviceWorkers.getAllRunning()` - -Returns `Record<Number, ServiceWorkerInfo>` - A [ServiceWorkerInfo](structures/service-worker-info.md) object where the keys are the service worker version ID and the values are the information about that service worker. - -#### `serviceWorkers.getFromVersionID(versionId)` - -* `versionId` Number - -Returns [`ServiceWorkerInfo`](structures/service-worker-info.md) - Information about this service worker - -If the service worker does not exist or is not running this method will throw an exception. diff --git a/content/current/cs-CZ/docs/api/structures/extension.md b/content/current/cs-CZ/docs/api/structures/extension.md deleted file mode 100644 index 38323eefcce9b..0000000000000 --- a/content/current/cs-CZ/docs/api/structures/extension.md +++ /dev/null @@ -1,8 +0,0 @@ -# Extension Object - -* `id` Text -* `manifest` any - Copy of the [extension's manifest data](https://developer.chrome.com/extensions/manifest). -* `name` String -* `path` String - The extension's file path. -* `version` String -* `url` String - The extension's `chrome-extension://` URL. diff --git a/content/current/cs-CZ/docs/api/structures/post-body.md b/content/current/cs-CZ/docs/api/structures/post-body.md deleted file mode 100644 index 75d01bc891e2a..0000000000000 --- a/content/current/cs-CZ/docs/api/structures/post-body.md +++ /dev/null @@ -1,19 +0,0 @@ -# PostBody Object - -* `data` Array<[PostData](./post-data.md)> - The post data to be sent to the new window. -* `contentType` String - The `content-type` header used for the data. One of `application/x-www-form-urlencoded` or `multipart/form-data`. Corresponds to the `enctype` attribute of the submitted HTML form. -* `boundary` String (optional) - The boundary used to separate multiple parts of the message. Only valid when `contentType` is `multipart/form-data`. - -Note that keys starting with `--` are not currently supported. For example, this will errantly submit as `multipart/form-data` when `nativeWindowOpen` is set to `false` in webPreferences: - -```html -<form - target="_blank" - method="POST" - enctype="application/x-www-form-urlencoded" - action="https://postman-echo.com/post" -> - <input type="text" name="--theKey"> - <input type="submit"> -</form> -``` diff --git a/content/current/cs-CZ/docs/api/structures/post-data.md b/content/current/cs-CZ/docs/api/structures/post-data.md deleted file mode 100644 index 0b80a9957b975..0000000000000 --- a/content/current/cs-CZ/docs/api/structures/post-data.md +++ /dev/null @@ -1,12 +0,0 @@ -# PostData Object - -* `type` String - One of the following: - * `rawData` - The data is available as a `Buffer`, in the `rawData` field. - * `file` - The object represents a file. The `filePath`, `offset`, `length` and `modificationTime` fields will be used to describe the file. - * `blob` - The object represents a `Blob`. The `blobUUID` field will be used to describe the `Blob`. -* `bytes` String (optional) - The raw bytes of the post data in a `Buffer`. Required for the `rawData` type. -* `filePath` String (optional) - The path of the file being uploaded. Required for the `file` type. -* `blobUUID` String (optional) - The `UUID` of the `Blob` being uploaded. Required for the `blob` type. -* `offset` Integer (optional) - The offset from the beginning of the file being uploaded, in bytes. Only valid for `file` types. -* `length` Integer (optional) - The length of the file being uploaded, in bytes. If set to `-1`, the whole file will be uploaded. Only valid for `file` types. -* `modificationTime` Double (optional) - The modification time of the file represented by a double, which is the number of seconds since the `UNIX Epoch` (Jan 1, 1970). Only valid for `file` types. diff --git a/content/current/cs-CZ/docs/api/structures/service-worker-info.md b/content/current/cs-CZ/docs/api/structures/service-worker-info.md deleted file mode 100644 index 578ef347744a2..0000000000000 --- a/content/current/cs-CZ/docs/api/structures/service-worker-info.md +++ /dev/null @@ -1,5 +0,0 @@ -# ServiceWorkerInfo Object - -* `scriptUrl` String - The full URL to the script that this service worker runs -* `scope` String - The base URL that this service worker is active for. -* `renderProcessId` Number - The virtual ID of the process that this service worker is running in. This is not an OS level PID. This aligns with the ID set used for `webContents.getProcessId()`. diff --git a/content/current/cs-CZ/docs/api/touch-bar-other-items-proxy.md b/content/current/cs-CZ/docs/api/touch-bar-other-items-proxy.md deleted file mode 100644 index 5eb60d1abf211..0000000000000 --- a/content/current/cs-CZ/docs/api/touch-bar-other-items-proxy.md +++ /dev/null @@ -1,9 +0,0 @@ -## Class: TouchBarOtherItemsProxy - -> Instantiates a special "other items proxy", which nests TouchBar elements inherited from Chromium at the space indicated by the proxy. By default, this proxy is added to each TouchBar at the end of the input. For more information, see the AppKit docs on [NSTouchBarItemIdentifierOtherItemsProxy](https://developer.apple.com/documentation/appkit/nstouchbaritemidentifierotheritemsproxy) -> -> Note: Only one instance of this class can be added per TouchBar. - -Process: [Main](../tutorial/application-architecture.md#main-and-renderer-processes) - -### `new TouchBarOtherItemsProxy()` diff --git a/content/current/en-US/docs/api/web-contents.md b/content/current/en-US/docs/api/web-contents.md index f0bbd117ee68e..131ac855a2a29 100644 --- a/content/current/en-US/docs/api/web-contents.md +++ b/content/current/en-US/docs/api/web-contents.md @@ -1826,7 +1826,7 @@ A [`WebContents`](web-contents.md) instance that might own this `WebContents`. #### `contents.devToolsWebContents` _Readonly_ -A `WebContents` of DevTools for this `WebContents`. +A `WebContents | null` property that represents the of DevTools `WebContents` associated with a given `WebContents`. **Note:** Users should never store this object because it may become `null` when the DevTools has been closed. diff --git a/content/current/en-US/docs/breaking-changes.md b/content/current/en-US/docs/breaking-changes.md index 151edd9b3b04e..6f36ce64f8390 100644 --- a/content/current/en-US/docs/breaking-changes.md +++ b/content/current/en-US/docs/breaking-changes.md @@ -12,8 +12,73 @@ This document uses the following convention to categorize breaking changes: - **Deprecated:** An API was marked as deprecated. The API will continue to function, but will emit a deprecation warning, and will be removed in a future release. - **Removed:** An API or feature was removed, and is no longer supported by Electron. +## Planned Breaking API Changes (12.0) + +### Removed: `crashReporter` methods in the renderer process + +The following `crashReporter` methods are no longer available in the renderer +process: + +- `crashReporter.start` +- `crashReporter.getLastCrashReport` +- `crashReporter.getUploadedReports` +- `crashReporter.getUploadToServer` +- `crashReporter.setUploadToServer` +- `crashReporter.getCrashesDirectory` + +They should be called only from the main process. + +See [#23265](https://github.com/electron/electron/pull/23265) for more details. + +## Planned Breaking API Changes (11.0) + ## Planned Breaking API Changes (10.0) +### Deprecated: `companyName` argument to `crashReporter.start()` + +The `companyName` argument to `crashReporter.start()`, which was previously +required, is now optional, and further, is deprecated. To get the same +behavior in a non-deprecated way, you can pass a `companyName` value in +`globalExtra`. + +```js +// Deprecated in Electron 10 +crashReporter.start({ companyName: 'Umbrella Corporation' }) +// Replace with +crashReporter.start({ globalExtra: { _companyName: 'Umbrella Corporation' } }) +``` + +### Deprecated: `crashReporter.getCrashesDirectory()` + +The `crashReporter.getCrashesDirectory` method has been deprecated. Usage +should be replaced by `app.getPath('crashDumps')`. + +```js +// Deprecated in Electron 10 +crashReporter.getCrashesDirectory() +// Replace with +app.getPath('crashDumps') +``` + +### Deprecated: `crashReporter` methods in the renderer process + +Calling the following `crashReporter` methods from the renderer process is +deprecated: + +- `crashReporter.start` +- `crashReporter.getLastCrashReport` +- `crashReporter.getUploadedReports` +- `crashReporter.getUploadToServer` +- `crashReporter.setUploadToServer` +- `crashReporter.getCrashesDirectory` + +The only non-deprecated methods remaining in the `crashReporter` module in the +renderer are `addExtraParameter`, `removeExtraParameter` and `getParameters`. + +All above methods remain non-deprecated when called from the main process. + +See [#23265](https://github.com/electron/electron/pull/23265) for more details. + ### Removed: Browser Window Affinity The `affinity` option when constructing a new `BrowserWindow` will be removed diff --git a/content/current/en-US/docs/development/build-instructions-gn.md b/content/current/en-US/docs/development/build-instructions-gn.md index baf7183f62b05..09f6ee2bcd49a 100644 --- a/content/current/en-US/docs/development/build-instructions-gn.md +++ b/content/current/en-US/docs/development/build-instructions-gn.md @@ -24,13 +24,12 @@ try to download a Google-internal version that only Googlers have access to). [depot-tools]: http://commondatastorage.googleapis.com/chrome-infra-docs/flat/depot_tools/docs/html/depot_tools_tutorial.html#_setting_up -## Cached builds (optional step) +### Setting up the git cache -### GIT\_CACHE\_PATH - -If you plan on building Electron more than once, adding a git cache will -speed up subsequent calls to `gclient`. To do this, set a `GIT_CACHE_PATH` -environment variable: +If you plan on checking out Electron more than once (for example, to have +multiple parallel directories checked out to different branches), using the git +cache will speed up subsequent calls to `gclient`. To do this, set a +`GIT_CACHE_PATH` environment variable: ```sh $ export GIT_CACHE_PATH="${HOME}/.git_cache" @@ -38,22 +37,10 @@ $ mkdir -p "${GIT_CACHE_PATH}" # This will use about 16G. ``` -### sccache - -Thousands of files must be compiled to build Chromium and Electron. -You can avoid much of the wait by reusing Electron CI's build output via -[sccache](https://github.com/mozilla/sccache). This requires some -optional steps (listed below) and these two environment variables: - -```sh -export SCCACHE_BUCKET="electronjs-sccache-ci" -export SCCACHE_TWO_TIER=true -``` - ## Getting the code ```sh -$ mkdir electron-gn && cd electron-gn +$ mkdir electron && cd electron $ gclient config --name "src/electron" --unmanaged https://github.com/electron/electron $ gclient sync --with_branch_heads --with_tags # This will take a while, go get a coffee. diff --git a/content/current/en-US/docs/tutorial/context-isolation.md b/content/current/en-US/docs/tutorial/context-isolation.md new file mode 100644 index 0000000000000..20d14a642840a --- /dev/null +++ b/content/current/en-US/docs/tutorial/context-isolation.md @@ -0,0 +1,70 @@ +# Context Isolation + +## What is it? + +Context Isolation is a feature that ensures that both your `preload` scripts and Electron's internal logic run in a separate context to the website you load in a [`webContents`](../api/web-contents.md). This is important for security purposes as it helps prevent the website from accessing Electron internals or the powerful APIs your preload script has access to. + +This means that the `window` object that your preload script has access to is actually a **different** object than the website would have access to. For example, if you set `window.hello = 'wave'` in your preload script and context isolation is enabled `window.hello` will be undefined if the website tries to access it. + +Every single application should have context isolation enabled and from Electron 12 it will be enabled by default. + +## How do I enable it? + +From Electron 12, it will be enabled by default. For lower versions it is an option in the `webPreferences` option when constructing `new BrowserWindow`'s. + +```javascript +const mainWindow = new BrowserWindow({ + webPreferences: { + contextIsolation: true + } +}) +``` + +## Migration + +> I used to provide APIs from my preload script using `window.X = apiObject` now what? + +Exposing APIs from your preload script to the loaded website is a common usecase and there is a dedicated module in Electron to help you do this in a painless way. + +**Before: With context isolation disabled** + +```javascript +window.myAPI = { + doAThing: () => {} +} +``` + +**After: With context isolation enabled** + +```javascript +const { contextBridge } = require('electron') + +contextBridge.exposeInMainWorld('myAPI', { + doAThing: () => {} +}) +``` + +The [`contextBridge`](../api/context-bridge.md) module can be used to **safely** expose APIs from the isolated context your preload script runs in to the context the website is running in. The API will also be accessible from the website on `window.myAPI` just like it was before. + +You should read the `contextBridge` documentation linked above to fully understand its limitations. For instance you can't send custom prototypes or symbols over the bridge. + +## Security Considerations + +Just enabling `contextIsolation` and using `contextBridge` does not automatically mean that everything you do is safe. For instance this code is **unsafe**. + +```javascript +// ❌ Bad code +contextBridge.exposeInMainWorld('myAPI', { + send: ipcRenderer.send +}) +``` + +It directly exposes a powerful API without any kind of argument filtering. This would allow any website to send arbitrary IPC messages which you do not want to be possible. The correct way to expose IPC-based APIs would instead be to provide one method per IPC message. + +```javascript +// ✅ Good code +contextBridge.exposeInMainWorld('myAPI', { + loadPreferences: () => ipcRenderer.invoke('load-prefs') +}) +``` + diff --git a/content/current/en-US/docs/tutorial/devtools-extension.md b/content/current/en-US/docs/tutorial/devtools-extension.md index df248944e84f2..135f8e0f82dcd 100644 --- a/content/current/en-US/docs/tutorial/devtools-extension.md +++ b/content/current/en-US/docs/tutorial/devtools-extension.md @@ -64,7 +64,7 @@ Following Devtools Extensions are tested and guaranteed to work in Electron: * [jQuery Debugger](https://chrome.google.com/webstore/detail/jquery-debugger/dbhhnnnpaeobfddmlalhnehgclcmjimi) * [AngularJS Batarang](https://chrome.google.com/webstore/detail/angularjs-batarang/ighdmehidhipcmcojjgiloacoafjmpfk) * [Vue.js devtools](https://chrome.google.com/webstore/detail/vuejs-devtools/nhdogjmejiglipccpnnnanhbledajbpd) -* [Cerebral Debugger](https://cerebraljs.com/docs/introduction/debugger.html) +* [Cerebral Debugger](https://cerebraljs.com/docs/introduction/devtools.html) * [Redux DevTools Extension](https://chrome.google.com/webstore/detail/redux-devtools/lmhkpmbekcpmknklioeibfkpmmfibljd) * [MobX Developer Tools](https://chrome.google.com/webstore/detail/mobx-developer-tools/pfgnfdagidkfgccljigdamigbcnndkod) diff --git a/content/current/en-US/docs/tutorial/performance.md b/content/current/en-US/docs/tutorial/performance.md index 87f41ab57b450..c3533af624747 100644 --- a/content/current/en-US/docs/tutorial/performance.md +++ b/content/current/en-US/docs/tutorial/performance.md @@ -42,7 +42,7 @@ improve performance. To learn more about how to profile your app's code, familiarize yourself with the Chrome Developer Tools. For advanced analysis looking at multiple processes -at once, consider the [Chrome Tracing] tool. +at once, consider the [Chrome Tracing](https://www.chromium.org/developers/how-tos/trace-event-profiling-tool) tool. ### Recommended Reading @@ -352,7 +352,7 @@ Many users of Electron start with an entirely web-based app that they're turning into a desktop application. As web developers, we are used to loading resources from a variety of content delivery networks. Now that you are shipping a proper desktop application, attempt to "cut the cord" where possible - - and avoid letting your users wait for resources that never change and could +and avoid letting your users wait for resources that never change and could easily be included in your app. A typical example is Google Fonts. Many developers make use of Google's diff --git a/content/current/en-US/docs/tutorial/security.md b/content/current/en-US/docs/tutorial/security.md index 4f864ea22163d..1eb899e126086 100644 --- a/content/current/en-US/docs/tutorial/security.md +++ b/content/current/en-US/docs/tutorial/security.md @@ -239,51 +239,10 @@ to enable this behavior. Even when you use `nodeIntegration: false` to enforce strong isolation and prevent the use of Node primitives, `contextIsolation` must also be used. -### Why? - -Context isolation allows each of the scripts running in the renderer to make -changes to its JavaScript environment without worrying about conflicting with -the scripts in the Electron API or the preload script. - -While still an experimental Electron feature, context isolation adds an -additional layer of security. It creates a new JavaScript world for Electron -APIs and preload scripts, which mitigates so-called "Prototype Pollution" attacks. - -At the same time, preload scripts still have access to the `document` and -`window` objects. In other words, you're getting a decent return on a likely -very small investment. - -### How? +### Why & How? -```js -// Main process -const mainWindow = new BrowserWindow({ - webPreferences: { - contextIsolation: true, - preload: path.join(app.getAppPath(), 'preload.js') - } -}) -``` - -```js -// Preload script - -// Set a variable in the page before it loads -webFrame.executeJavaScript('window.foo = "foo";') - -// The loaded page will not be able to access this, it is only available -// in this context -window.bar = 'bar' - -document.addEventListener('DOMContentLoaded', () => { - // Will log out 'undefined' since window.foo is only available in the main - // context - console.log(window.foo) - - // Will log out 'bar' since window.bar is available in this context - console.log(window.bar) -}) -``` +For more information on what `contextIsolation` is and how to enable it please +see our dedicated [Context Isolation](context-isolation.md) document. ## 4) Handle Session Permission Requests From Remote Content diff --git a/content/current/en-US/docs/tutorial/spellchecker.md b/content/current/en-US/docs/tutorial/spellchecker.md new file mode 100644 index 0000000000000..cd1f53c9afd0e --- /dev/null +++ b/content/current/en-US/docs/tutorial/spellchecker.md @@ -0,0 +1,74 @@ +# SpellChecker + +Electron has built-in support for Chromium's spellchecker since Electron 8. On Windows and Linux this is powered by Hunspell dictionaries, and on macOS it makes use of the native spellchecker APIs. + +## How to enable the spellchecker? + +For Electron 9 and higher the spellchecker is enabled by default. For Electron 8 you need to enable it in `webPreferences`. + +```js +const myWindow = new BrowserWindow({ + webPreferences: { + spellcheck: true + } +}) +``` + +## How to set the languages the spellchecker uses? + +On macOS as we use the native APIs there is no way to set the language that the spellchecker uses. By default on macOS the native spellchecker will automatically detect the language being used for you. + +For Windows and Linux there are a few Electron APIs you should use to set the languages for the spellchecker. + +```js +// Sets the spellchecker to check English US and French +myWindow.session.setSpellCheckerLanguages(['en-US', 'fr']) + +// An array of all available language codes +const possibleLanguages = myWindow.session.availableSpellCheckerLanguages +``` + +By default the spellchecker will enable the language matching the current OS locale. + +## How do I put the results of the spellchecker in my context menu? + +All the required information to generate a context menu is provided in the [`context-menu`](../api/web-contents.md#event-context-menu) event on each `webContents` instance. A small example +of how to make a context menu with this information is provided below. + +```js +const { Menu, MenuItem } = require('electron') + +myWindow.webContents.on('context-menu', (event, params) => { + const menu = new Menu() + + // Add each spelling suggestion + for (const suggestion of params.dictionarySuggestions) { + menu.append(new MenuItem({ + label: suggestion, + click: () => mainWindow.webContents.replaceMisspelling(suggestion) + })) + } + + // Allow users to add the misspelled word to the dictionary + if (params.misspelledWord) { + menu.append( + new MenuItem({ + label: 'Add to dictionary', + click: () => mainWindow.webContents.session.addWordToSpellCheckerDictionary(params.misspelledWord) + }) + ) + } + + menu.popup() +}) +``` + +## Does the spellchecker use any Google services? + +Although the spellchecker itself does not send any typings, words or user input to Google services the hunspell dictionary files are downloaded from a Google CDN by default. If you want to avoid this you can provide an alternative URL to download the dictionaries from. + +```js +myWindow.session.setSpellCheckerDictionaryDownloadURL('https://example.com/dictionaries/') +``` + +Check out the docs for [`session.setSpellCheckerDictionaryDownloadURL`](https://www.electronjs.org/docs/api/session#sessetspellcheckerdictionarydownloadurlurl) for more information on where to get the dictionary files from and how you need to host them. diff --git a/content/current/en-US/docs/tutorial/updates.md b/content/current/en-US/docs/tutorial/updates.md index eafbea97ce782..683bb1ce0713b 100644 --- a/content/current/en-US/docs/tutorial/updates.md +++ b/content/current/en-US/docs/tutorial/updates.md @@ -80,9 +80,9 @@ Next, construct the URL of the update server and tell ```javascript const server = 'https://your-deployment-url.com' -const feed = `${server}/update/${process.platform}/${app.getVersion()}` +const url = `${server}/update/${process.platform}/${app.getVersion()}` -autoUpdater.setFeedURL(feed) +autoUpdater.setFeedURL({ url }) ``` As the final step, check for updates. The example below will check every minute: @@ -132,6 +132,10 @@ autoUpdater.on('error', message => { }) ``` +## Handing Updates Manually + +Because the requests made by Auto Update aren't under your direct control, you may find situations that are difficult to handle (such as if the update server is behind authentication). The `url` field does support files, which means that with some effort, you can sidestep the server-communication aspect of the process. [Here's an example of how this could work](https://github.com/electron/electron/issues/5020#issuecomment-477636990). + [now]: https://zeit.co/now [hazel]: https://github.com/zeit/hazel [nuts]: https://github.com/GitbookIO/nuts diff --git a/content/current/en-US/electron-api.json b/content/current/en-US/electron-api.json index 30d2c0af029c0..7ef0c86b064e6 100644 --- a/content/current/en-US/electron-api.json +++ b/content/current/en-US/electron-api.json @@ -4,8 +4,8 @@ "description": "", "slug": "app", "websiteUrl": "http://electronjs.org/docs/api/app", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/app.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/app.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -2403,8 +2403,8 @@ "description": "", "slug": "auto-updater", "websiteUrl": "http://electronjs.org/docs/api/auto-updater", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/auto-updater.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/auto-updater.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -2592,8 +2592,8 @@ "description": "", "slug": "browser-view", "websiteUrl": "http://electronjs.org/docs/api/browser-view", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/browser-view.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/browser-view.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -2836,8 +2836,8 @@ "description": "", "slug": "browser-window-proxy", "websiteUrl": "http://electronjs.org/docs/api/browser-window-proxy", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/browser-window-proxy.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/browser-window-proxy.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -2939,8 +2939,8 @@ "description": "", "slug": "browser-window", "websiteUrl": "http://electronjs.org/docs/api/browser-window", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/browser-window.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/browser-window.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -6893,8 +6893,8 @@ "description": "", "slug": "client-request", "websiteUrl": "http://electronjs.org/docs/api/client-request", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/client-request.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/client-request.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -7433,8 +7433,8 @@ "description": "", "slug": "clipboard", "websiteUrl": "http://electronjs.org/docs/api/clipboard", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/clipboard.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/clipboard.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -8078,8 +8078,8 @@ "description": "", "slug": "command-line", "websiteUrl": "http://electronjs.org/docs/api/command-line", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/command-line.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/command-line.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -8182,8 +8182,8 @@ "description": "", "slug": "content-tracing", "websiteUrl": "http://electronjs.org/docs/api/content-tracing", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/content-tracing.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/content-tracing.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -8313,8 +8313,8 @@ "description": "", "slug": "context-bridge", "websiteUrl": "http://electronjs.org/docs/api/context-bridge", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/context-bridge.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/context-bridge.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -8367,8 +8367,8 @@ "description": "", "slug": "cookies", "websiteUrl": "http://electronjs.org/docs/api/cookies", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/cookies.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/cookies.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -8621,8 +8621,8 @@ "description": "", "slug": "crash-reporter", "websiteUrl": "http://electronjs.org/docs/api/crash-reporter", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/crash-reporter.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/crash-reporter.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -8845,8 +8845,8 @@ "description": "", "slug": "debugger", "websiteUrl": "http://electronjs.org/docs/api/debugger", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/debugger.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/debugger.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -8987,8 +8987,8 @@ "description": "", "slug": "desktop-capturer", "websiteUrl": "http://electronjs.org/docs/api/desktop-capturer", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/desktop-capturer.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/desktop-capturer.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -9056,8 +9056,8 @@ "description": "", "slug": "dialog", "websiteUrl": "http://electronjs.org/docs/api/dialog", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/dialog.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/dialog.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -10074,8 +10074,8 @@ "description": "", "slug": "dock", "websiteUrl": "http://electronjs.org/docs/api/dock", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/dock.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/dock.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -10306,8 +10306,8 @@ "description": "", "slug": "download-item", "websiteUrl": "http://electronjs.org/docs/api/download-item", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/download-item.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/download-item.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -10663,8 +10663,8 @@ "description": "", "slug": "global-shortcut", "websiteUrl": "http://electronjs.org/docs/api/global-shortcut", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/global-shortcut.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/global-shortcut.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -10777,8 +10777,8 @@ "description": "", "slug": "in-app-purchase", "websiteUrl": "http://electronjs.org/docs/api/in-app-purchase", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/in-app-purchase.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/in-app-purchase.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -10908,8 +10908,8 @@ "description": "", "slug": "incoming-message", "websiteUrl": "http://electronjs.org/docs/api/incoming-message", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/incoming-message.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/incoming-message.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -11022,8 +11022,8 @@ "description": "", "slug": "ipc-main", "websiteUrl": "http://electronjs.org/docs/api/ipc-main", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/ipc-main.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/ipc-main.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -11307,8 +11307,8 @@ "description": "", "slug": "ipc-renderer", "websiteUrl": "http://electronjs.org/docs/api/ipc-renderer", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/ipc-renderer.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/ipc-renderer.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -11596,8 +11596,8 @@ "description": "", "slug": "menu-item", "websiteUrl": "http://electronjs.org/docs/api/menu-item", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/menu-item.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/menu-item.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -12400,8 +12400,8 @@ "description": "", "slug": "menu", "websiteUrl": "http://electronjs.org/docs/api/menu", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/menu.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/menu.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -12692,8 +12692,8 @@ "description": "", "slug": "native-image", "websiteUrl": "http://electronjs.org/docs/api/native-image", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/native-image.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/native-image.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -12893,8 +12893,8 @@ "description": "", "slug": "native-image", "websiteUrl": "http://electronjs.org/docs/api/native-image", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/native-image.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/native-image.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -13258,8 +13258,8 @@ "description": "", "slug": "native-theme", "websiteUrl": "http://electronjs.org/docs/api/native-theme", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/native-theme.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/native-theme.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -13338,8 +13338,8 @@ "description": "", "slug": "net-log", "websiteUrl": "http://electronjs.org/docs/api/net-log", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/net-log.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/net-log.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -13461,8 +13461,8 @@ "description": "", "slug": "net", "websiteUrl": "http://electronjs.org/docs/api/net", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/net.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/net.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -13507,8 +13507,8 @@ "description": "", "slug": "notification", "websiteUrl": "http://electronjs.org/docs/api/notification", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/notification.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/notification.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -13936,8 +13936,8 @@ "description": "", "slug": "power-monitor", "websiteUrl": "http://electronjs.org/docs/api/power-monitor", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/power-monitor.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/power-monitor.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -14057,8 +14057,8 @@ "description": "", "slug": "power-save-blocker", "websiteUrl": "http://electronjs.org/docs/api/power-save-blocker", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/power-save-blocker.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/power-save-blocker.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -14138,8 +14138,8 @@ "description": "", "slug": "process", "websiteUrl": "http://electronjs.org/docs/api/process", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/process.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/process.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -14607,8 +14607,8 @@ "description": "", "slug": "protocol", "websiteUrl": "http://electronjs.org/docs/api/protocol", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/protocol.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/protocol.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -16132,8 +16132,8 @@ "description": "", "slug": "remote", "websiteUrl": "http://electronjs.org/docs/api/remote", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/remote.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/remote.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -16222,8 +16222,8 @@ "description": "", "slug": "screen", "websiteUrl": "http://electronjs.org/docs/api/screen", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/screen.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/screen.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -16498,8 +16498,8 @@ "description": "", "slug": "session", "websiteUrl": "http://electronjs.org/docs/api/session", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/session.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/session.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -16561,8 +16561,8 @@ "description": "", "slug": "session", "websiteUrl": "http://electronjs.org/docs/api/session", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/session.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/session.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -17708,8 +17708,8 @@ "description": "", "slug": "shell", "websiteUrl": "http://electronjs.org/docs/api/shell", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/shell.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/shell.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -17925,8 +17925,8 @@ "description": "", "slug": "system-preferences", "websiteUrl": "http://electronjs.org/docs/api/system-preferences", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/system-preferences.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/system-preferences.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -19316,8 +19316,8 @@ "description": "", "slug": "touch-bar-button", "websiteUrl": "http://electronjs.org/docs/api/touch-bar-button", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/touch-bar-button.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/touch-bar-button.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -19462,8 +19462,8 @@ "description": "", "slug": "touch-bar-color-picker", "websiteUrl": "http://electronjs.org/docs/api/touch-bar-color-picker", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/touch-bar-color-picker.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/touch-bar-color-picker.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -19551,8 +19551,8 @@ "description": "", "slug": "touch-bar-group", "websiteUrl": "http://electronjs.org/docs/api/touch-bar-group", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/touch-bar-group.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/touch-bar-group.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -19592,8 +19592,8 @@ "description": "", "slug": "touch-bar-label", "websiteUrl": "http://electronjs.org/docs/api/touch-bar-label", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/touch-bar-label.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/touch-bar-label.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -19680,8 +19680,8 @@ "description": "", "slug": "touch-bar-popover", "websiteUrl": "http://electronjs.org/docs/api/touch-bar-popover", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/touch-bar-popover.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/touch-bar-popover.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -19764,8 +19764,8 @@ "description": "", "slug": "touch-bar-scrubber", "websiteUrl": "http://electronjs.org/docs/api/touch-bar-scrubber", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/touch-bar-scrubber.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/touch-bar-scrubber.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -20006,8 +20006,8 @@ "description": "", "slug": "touch-bar-segmented-control", "websiteUrl": "http://electronjs.org/docs/api/touch-bar-segmented-control", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/touch-bar-segmented-control.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/touch-bar-segmented-control.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -20170,8 +20170,8 @@ "description": "", "slug": "touch-bar-slider", "websiteUrl": "http://electronjs.org/docs/api/touch-bar-slider", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/touch-bar-slider.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/touch-bar-slider.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -20288,8 +20288,8 @@ "description": "", "slug": "touch-bar-spacer", "websiteUrl": "http://electronjs.org/docs/api/touch-bar-spacer", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/touch-bar-spacer.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/touch-bar-spacer.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -20343,8 +20343,8 @@ "description": "", "slug": "touch-bar", "websiteUrl": "http://electronjs.org/docs/api/touch-bar", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/touch-bar.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/touch-bar.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -20552,8 +20552,8 @@ "description": "", "slug": "tray", "websiteUrl": "http://electronjs.org/docs/api/tray", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/tray.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/tray.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -21194,8 +21194,8 @@ "description": "", "slug": "web-contents", "websiteUrl": "http://electronjs.org/docs/api/web-contents", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/web-contents.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/web-contents.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -21252,8 +21252,8 @@ "description": "", "slug": "web-contents", "websiteUrl": "http://electronjs.org/docs/api/web-contents", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/web-contents.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/web-contents.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -23536,13 +23536,22 @@ }, { "name": "devToolsWebContents", - "description": "A `WebContents` of DevTools for this `WebContents`.\n\n**Note:** Users should never store this object because it may become `null` when the DevTools has been closed.", + "description": "A `WebContents | null` property that represents the of DevTools `WebContents` associated with a given `WebContents`.\n\n**Note:** Users should never store this object because it may become `null` when the DevTools has been closed.", "required": true, "additionalTags": [ "availability_readonly" ], "collection": false, - "type": "WebContents" + "type": [ + { + "collection": false, + "type": "WebContents" + }, + { + "type": "null", + "collection": false + } + ] }, { "name": "debugger", @@ -25567,8 +25576,8 @@ "description": "", "slug": "web-frame", "websiteUrl": "http://electronjs.org/docs/api/web-frame", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/web-frame.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/web-frame.md", + "version": "8.2.5", "type": "Module", "process": { "main": true, @@ -26162,8 +26171,8 @@ "description": "", "slug": "web-request", "websiteUrl": "http://electronjs.org/docs/api/web-request", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/web-request.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/web-request.md", + "version": "8.2.5", "type": "Class", "process": { "main": true, @@ -27527,8 +27536,8 @@ "description": "", "slug": "webview-tag", "websiteUrl": "http://electronjs.org/docs/api/webview-tag", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/webview-tag.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/webview-tag.md", + "version": "8.2.5", "type": "Element", "process": { "main": true, @@ -29290,8 +29299,8 @@ "description": "", "slug": "bluetooth-device", "websiteUrl": "http://electronjs.org/docs/api/structures/bluetooth-device", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/bluetooth-device.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/bluetooth-device.md", + "version": "8.2.5", "properties": [ { "name": "deviceName", @@ -29319,8 +29328,8 @@ "description": "", "slug": "certificate-principal", "websiteUrl": "http://electronjs.org/docs/api/structures/certificate-principal", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/certificate-principal.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/certificate-principal.md", + "version": "8.2.5", "properties": [ { "name": "commonName", @@ -29384,8 +29393,8 @@ "description": "", "slug": "certificate", "websiteUrl": "http://electronjs.org/docs/api/structures/certificate", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/certificate.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/certificate.md", + "version": "8.2.5", "properties": [ { "name": "data", @@ -29480,8 +29489,8 @@ "description": "", "slug": "cookie", "websiteUrl": "http://electronjs.org/docs/api/structures/cookie", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/cookie.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/cookie.md", + "version": "8.2.5", "properties": [ { "name": "name", @@ -29567,8 +29576,8 @@ "description": "", "slug": "cpu-usage", "websiteUrl": "http://electronjs.org/docs/api/structures/cpu-usage", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/cpu-usage.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/cpu-usage.md", + "version": "8.2.5", "properties": [ { "name": "percentCPUUsage", @@ -29594,8 +29603,8 @@ "description": "", "slug": "crash-report", "websiteUrl": "http://electronjs.org/docs/api/structures/crash-report", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/crash-report.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/crash-report.md", + "version": "8.2.5", "properties": [ { "name": "date", @@ -29622,8 +29631,8 @@ "description": "", "slug": "custom-scheme", "websiteUrl": "http://electronjs.org/docs/api/structures/custom-scheme", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/custom-scheme.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/custom-scheme.md", + "version": "8.2.5", "properties": [ { "name": "scheme", @@ -29700,8 +29709,8 @@ "description": "", "slug": "desktop-capturer-source", "websiteUrl": "http://electronjs.org/docs/api/structures/desktop-capturer-source", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/desktop-capturer-source.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/desktop-capturer-source.md", + "version": "8.2.5", "properties": [ { "name": "id", @@ -29754,8 +29763,8 @@ "description": "The `Display` object represents a physical display connected to the system. A fake `Display` may exist on a headless system, or a `Display` may correspond to a remote, virtual display.", "slug": "display", "websiteUrl": "http://electronjs.org/docs/api/structures/display", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/display.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/display.md", + "version": "8.2.5", "properties": [ { "name": "id", @@ -29907,8 +29916,8 @@ "description": "", "slug": "event", "websiteUrl": "http://electronjs.org/docs/api/structures/event", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/event.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/event.md", + "version": "8.2.5", "properties": [ { "name": "preventDefault", @@ -29926,8 +29935,8 @@ "description": "", "slug": "extension-info", "websiteUrl": "http://electronjs.org/docs/api/structures/extension-info", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/extension-info.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/extension-info.md", + "version": "8.2.5", "properties": [ { "name": "name", @@ -29955,8 +29964,8 @@ "description": "", "slug": "file-filter", "websiteUrl": "http://electronjs.org/docs/api/structures/file-filter", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/file-filter.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/file-filter.md", + "version": "8.2.5", "properties": [ { "name": "name", @@ -29984,8 +29993,8 @@ "description": "", "slug": "file-path-with-headers", "websiteUrl": "http://electronjs.org/docs/api/structures/file-path-with-headers", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/file-path-with-headers.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/file-path-with-headers.md", + "version": "8.2.5", "properties": [ { "name": "path", @@ -30022,8 +30031,8 @@ "description": "Possible values:\n\n* `disabled_software` - Software only. Hardware acceleration disabled (yellow)\n* `disabled_off` - Disabled (red)\n* `disabled_off_ok` - Disabled (yellow)\n* `unavailable_software` - Software only, hardware acceleration unavailable (yellow)\n* `unavailable_off` - Unavailable (red)\n* `unavailable_off_ok` - Unavailable (yellow)\n* `enabled_readback` - Hardware accelerated but at reduced performance (yellow)\n* `enabled_force` - Hardware accelerated on all pages (green)\n* `enabled` - Hardware accelerated (green)\n* `enabled_on` - Enabled (green)\n* `enabled_force_on` - Force enabled (green)", "slug": "gpu-feature-status", "websiteUrl": "http://electronjs.org/docs/api/structures/gpu-feature-status", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/gpu-feature-status.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/gpu-feature-status.md", + "version": "8.2.5", "properties": [ { "name": "2d_canvas", @@ -30150,8 +30159,8 @@ "description": "", "slug": "input-event", "websiteUrl": "http://electronjs.org/docs/api/structures/input-event", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/input-event.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/input-event.md", + "version": "8.2.5", "properties": [ { "name": "modifiers", @@ -30235,8 +30244,8 @@ "description": "", "slug": "io-counters", "websiteUrl": "http://electronjs.org/docs/api/structures/io-counters", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/io-counters.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/io-counters.md", + "version": "8.2.5", "properties": [ { "name": "readOperationCount", @@ -30295,8 +30304,8 @@ "description": "", "slug": "ipc-main-event", "websiteUrl": "http://electronjs.org/docs/api/structures/ipc-main-event", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/ipc-main-event.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/ipc-main-event.md", + "version": "8.2.5", "properties": [ { "name": "frameId", @@ -30349,8 +30358,8 @@ "description": "", "slug": "ipc-main-invoke-event", "websiteUrl": "http://electronjs.org/docs/api/structures/ipc-main-invoke-event", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/ipc-main-invoke-event.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/ipc-main-invoke-event.md", + "version": "8.2.5", "properties": [ { "name": "frameId", @@ -30377,8 +30386,8 @@ "description": "", "slug": "ipc-renderer-event", "websiteUrl": "http://electronjs.org/docs/api/structures/ipc-renderer-event", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/ipc-renderer-event.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/ipc-renderer-event.md", + "version": "8.2.5", "properties": [ { "name": "sender", @@ -30404,8 +30413,8 @@ "description": "**Note:** If a `JumpListCategory` object has neither the `type` nor the `name` property set then its `type` is assumed to be `tasks`. If the `name` property is set but the `type` property is omitted then the `type` is assumed to be `custom`.", "slug": "jump-list-category", "websiteUrl": "http://electronjs.org/docs/api/structures/jump-list-category", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/jump-list-category.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/jump-list-category.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -30458,8 +30467,8 @@ "description": "", "slug": "jump-list-item", "websiteUrl": "http://electronjs.org/docs/api/structures/jump-list-item", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/jump-list-item.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/jump-list-item.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -30563,8 +30572,8 @@ "description": "", "slug": "keyboard-event", "websiteUrl": "http://electronjs.org/docs/api/structures/keyboard-event", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/keyboard-event.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/keyboard-event.md", + "version": "8.2.5", "properties": [ { "name": "ctrlKey", @@ -30615,8 +30624,8 @@ "description": "", "slug": "keyboard-input-event", "websiteUrl": "http://electronjs.org/docs/api/structures/keyboard-input-event", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/keyboard-input-event.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/keyboard-input-event.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -30657,8 +30666,8 @@ "description": "Note that all statistics are reported in Kilobytes.", "slug": "memory-info", "websiteUrl": "http://electronjs.org/docs/api/structures/memory-info", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/memory-info.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/memory-info.md", + "version": "8.2.5", "properties": [ { "name": "workingSetSize", @@ -30694,8 +30703,8 @@ "description": "", "slug": "memory-usage-details", "websiteUrl": "http://electronjs.org/docs/api/structures/memory-usage-details", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/memory-usage-details.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/memory-usage-details.md", + "version": "8.2.5", "properties": [ { "name": "count", @@ -30729,8 +30738,8 @@ "description": "", "slug": "mime-typed-buffer", "websiteUrl": "http://electronjs.org/docs/api/structures/mime-typed-buffer", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/mime-typed-buffer.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/mime-typed-buffer.md", + "version": "8.2.5", "properties": [ { "name": "mimeType", @@ -30758,8 +30767,8 @@ "description": "", "slug": "mouse-input-event", "websiteUrl": "http://electronjs.org/docs/api/structures/mouse-input-event", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/mouse-input-event.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/mouse-input-event.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -30886,8 +30895,8 @@ "description": "", "slug": "mouse-wheel-input-event", "websiteUrl": "http://electronjs.org/docs/api/structures/mouse-wheel-input-event", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/mouse-wheel-input-event.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/mouse-wheel-input-event.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -30975,8 +30984,8 @@ "description": "", "slug": "notification-action", "websiteUrl": "http://electronjs.org/docs/api/structures/notification-action", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/notification-action.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/notification-action.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -31009,8 +31018,8 @@ "description": "**Note:** Both `x` and `y` must be whole integers, when providing a point object as input to an Electron API we will automatically round your `x` and `y` values to the nearest whole integer.", "slug": "point", "websiteUrl": "http://electronjs.org/docs/api/structures/point", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/point.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/point.md", + "version": "8.2.5", "properties": [ { "name": "x", @@ -31036,8 +31045,8 @@ "description": "", "slug": "printer-info", "websiteUrl": "http://electronjs.org/docs/api/structures/printer-info", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/printer-info.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/printer-info.md", + "version": "8.2.5", "properties": [ { "name": "name", @@ -31081,8 +31090,8 @@ "description": "", "slug": "process-memory-info", "websiteUrl": "http://electronjs.org/docs/api/structures/process-memory-info", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/process-memory-info.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/process-memory-info.md", + "version": "8.2.5", "properties": [ { "name": "residentSet", @@ -31119,8 +31128,8 @@ "description": "", "slug": "process-metric", "websiteUrl": "http://electronjs.org/docs/api/structures/process-metric", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/process-metric.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/process-metric.md", + "version": "8.2.5", "properties": [ { "name": "pid", @@ -31251,8 +31260,8 @@ "description": "", "slug": "product", "websiteUrl": "http://electronjs.org/docs/api/structures/product", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/product.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/product.md", + "version": "8.2.5", "properties": [ { "name": "productIdentifier", @@ -31331,8 +31340,8 @@ "description": "", "slug": "protocol-request", "websiteUrl": "http://electronjs.org/docs/api/structures/protocol-request", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/protocol-request.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/protocol-request.md", + "version": "8.2.5", "properties": [ { "name": "url", @@ -31377,8 +31386,8 @@ "description": "", "slug": "protocol-response-upload-data", "websiteUrl": "http://electronjs.org/docs/api/structures/protocol-response-upload-data", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/protocol-response-upload-data.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/protocol-response-upload-data.md", + "version": "8.2.5", "properties": [ { "name": "contentType", @@ -31415,8 +31424,8 @@ "description": "", "slug": "protocol-response", "websiteUrl": "http://electronjs.org/docs/api/structures/protocol-response", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/protocol-response.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/protocol-response.md", + "version": "8.2.5", "properties": [ { "name": "error", @@ -31561,8 +31570,8 @@ "description": "", "slug": "rectangle", "websiteUrl": "http://electronjs.org/docs/api/structures/rectangle", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/rectangle.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/rectangle.md", + "version": "8.2.5", "properties": [ { "name": "x", @@ -31604,8 +31613,8 @@ "description": "", "slug": "referrer", "websiteUrl": "http://electronjs.org/docs/api/structures/referrer", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/referrer.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/referrer.md", + "version": "8.2.5", "properties": [ { "name": "url", @@ -31666,8 +31675,8 @@ "description": "", "slug": "remove-client-certificate", "websiteUrl": "http://electronjs.org/docs/api/structures/remove-client-certificate", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/remove-client-certificate.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/remove-client-certificate.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -31695,8 +31704,8 @@ "description": "", "slug": "remove-password", "websiteUrl": "http://electronjs.org/docs/api/structures/remove-password", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/remove-password.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/remove-password.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -31777,8 +31786,8 @@ "description": "", "slug": "scrubber-item", "websiteUrl": "http://electronjs.org/docs/api/structures/scrubber-item", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/scrubber-item.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/scrubber-item.md", + "version": "8.2.5", "properties": [ { "name": "label", @@ -31805,8 +31814,8 @@ "description": "", "slug": "segmented-control-segment", "websiteUrl": "http://electronjs.org/docs/api/structures/segmented-control-segment", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/segmented-control-segment.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/segmented-control-segment.md", + "version": "8.2.5", "properties": [ { "name": "label", @@ -31841,8 +31850,8 @@ "description": "", "slug": "shared-worker-info", "websiteUrl": "http://electronjs.org/docs/api/structures/shared-worker-info", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/shared-worker-info.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/shared-worker-info.md", + "version": "8.2.5", "properties": [ { "name": "id", @@ -31870,8 +31879,8 @@ "description": "", "slug": "shortcut-details", "websiteUrl": "http://electronjs.org/docs/api/structures/shortcut-details", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/shortcut-details.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/shortcut-details.md", + "version": "8.2.5", "properties": [ { "name": "target", @@ -31943,8 +31952,8 @@ "description": "", "slug": "size", "websiteUrl": "http://electronjs.org/docs/api/structures/size", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/size.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/size.md", + "version": "8.2.5", "properties": [ { "name": "width", @@ -31970,8 +31979,8 @@ "description": "", "slug": "stream-protocol-response", "websiteUrl": "http://electronjs.org/docs/api/structures/stream-protocol-response", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/stream-protocol-response.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/stream-protocol-response.md", + "version": "8.2.5", "properties": [ { "name": "statusCode", @@ -32036,8 +32045,8 @@ "description": "", "slug": "string-protocol-response", "websiteUrl": "http://electronjs.org/docs/api/structures/string-protocol-response", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/string-protocol-response.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/string-protocol-response.md", + "version": "8.2.5", "properties": [ { "name": "mimeType", @@ -32083,8 +32092,8 @@ "description": "", "slug": "task", "websiteUrl": "http://electronjs.org/docs/api/structures/task", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/task.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/task.md", + "version": "8.2.5", "properties": [ { "name": "program", @@ -32156,8 +32165,8 @@ "description": "The `flags` is an array that can include following `String`s:\n\n* `enabled` - The button is active and available to the user.\n* `disabled` - The button is disabled. It is present, but has a visual state indicating it will not respond to user action.\n* `dismissonclick` - When the button is clicked, the thumbnail window closes immediately.\n* `nobackground` - Do not draw a button border, use only the image.\n* `hidden` - The button is not shown to the user.\n* `noninteractive` - The button is enabled but not interactive; no pressed button state is drawn. This value is intended for instances where the button is used in a notification.", "slug": "thumbar-button", "websiteUrl": "http://electronjs.org/docs/api/structures/thumbar-button", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/thumbar-button.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/thumbar-button.md", + "version": "8.2.5", "properties": [ { "name": "icon", @@ -32203,8 +32212,8 @@ "description": "", "slug": "trace-categories-and-options", "websiteUrl": "http://electronjs.org/docs/api/structures/trace-categories-and-options", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/trace-categories-and-options.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/trace-categories-and-options.md", + "version": "8.2.5", "properties": [ { "name": "categoryFilter", @@ -32232,8 +32241,8 @@ "description": "An example TraceConfig that roughly matches what Chrome DevTools records:", "slug": "trace-config", "websiteUrl": "http://electronjs.org/docs/api/structures/trace-config", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/trace-config.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/trace-config.md", + "version": "8.2.5", "properties": [ { "name": "recording_mode", @@ -32347,8 +32356,8 @@ "description": "", "slug": "transaction", "websiteUrl": "http://electronjs.org/docs/api/structures/transaction", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/transaction.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/transaction.md", + "version": "8.2.5", "properties": [ { "name": "transactionIdentifier", @@ -32459,8 +32468,8 @@ "description": "", "slug": "upload-blob", "websiteUrl": "http://electronjs.org/docs/api/structures/upload-blob", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/upload-blob.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/upload-blob.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -32488,8 +32497,8 @@ "description": "", "slug": "upload-data", "websiteUrl": "http://electronjs.org/docs/api/structures/upload-data", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/upload-data.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/upload-data.md", + "version": "8.2.5", "properties": [ { "name": "bytes", @@ -32525,8 +32534,8 @@ "description": "", "slug": "upload-file", "websiteUrl": "http://electronjs.org/docs/api/structures/upload-file", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/upload-file.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/upload-file.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -32578,8 +32587,8 @@ "description": "", "slug": "upload-raw-data", "websiteUrl": "http://electronjs.org/docs/api/structures/upload-raw-data", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/upload-raw-data.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/upload-raw-data.md", + "version": "8.2.5", "properties": [ { "name": "type", @@ -32606,8 +32615,8 @@ "description": "", "slug": "web-source", "websiteUrl": "http://electronjs.org/docs/api/structures/web-source", - "repoUrl": "https://github.com/electron/electron/blob/8.2.3/docs/api/docs/api/structures/web-source.md", - "version": "8.2.3", + "repoUrl": "https://github.com/electron/electron/blob/8.2.5/docs/api/docs/api/structures/web-source.md", + "version": "8.2.5", "properties": [ { "name": "code", diff --git a/content/current/en-US/website/blog/cadence-pause.md b/content/current/en-US/website/blog/cadence-pause.md index 70e4c2e3d1006..2d80491e364d3 100644 --- a/content/current/en-US/website/blog/cadence-pause.md +++ b/content/current/en-US/website/blog/cadence-pause.md @@ -16,4 +16,6 @@ We feel that our best choice is to follow in Chromium's footsteps, and so in the We want to ensure that both our maintainers and our consumers' wellbeing is prioritized during this time, so we welcome your feedback and look forward to returning to our regular release schedule. -For more updates, please follow our [Twitter account](https://twitter.com/electronjs). \ No newline at end of file +For more updates, please follow our [Twitter account](https://twitter.com/electronjs). + +Edit (2020-03-30): Electron 9 stable will target Chromium M83 and be released on May 19, 2020, in response to [Chromium's announcement](https://chromereleases.googleblog.com/2020/03/chrome-and-chrome-os-release-updates.html) of skipping the M82 stable date and adjusting the M83 stable date. diff --git a/content/current/en-US/website/locale.yml b/content/current/en-US/website/locale.yml index f9638e3e5d1f1..a638de1f3f553 100644 --- a/content/current/en-US/website/locale.yml +++ b/content/current/en-US/website/locale.yml @@ -142,6 +142,12 @@ releases: all_releases: All Releases back_to_index: Back to index +electron_is_good: + title: Apps users love, built with Electron + description: + Thousands of organizations spanning all industries use Electron to build + cross-platform software. + electron_is_easy: title: It's easier than you think description: @@ -149,7 +155,6 @@ electron_is_easy: framework for creating native applications with web technologies like JavaScript, HTML, and CSS. It takes care of the hard parts so you can focus on the core of your application. - video_link: Watch the video web_technologies: title: Web Technologies @@ -224,19 +229,7 @@ help_translate: "Help translate" footer: see_the_faq: See the frequently asked questions -companies: - title: Built on Electron - description: - Initially developed for GitHub's - <a href='https://atom.io' target='_blank'>Atom editor</a>, Electron has - since been adopted by companies all over the world. apps: - description: - With Electron, creating a desktop application for your company or idea - is easy. Check out <a href='/apps'>some of the apps created by the community</a> or - <a href="https://github.com/electron/electron-apps/blob/master/contributing.md#adding-your-app">add your own</a>. - view_more: View more apps - submit_your_own: submit your own something_missing: Something missing? edit_this_app: Edit this app. search_app: Filter apps by name, description, etc… diff --git a/content/current/zh-CN/docs/api/extensions.md b/content/current/zh-CN/docs/api/extensions.md deleted file mode 100644 index 38fd90183978d..0000000000000 --- a/content/current/zh-CN/docs/api/extensions.md +++ /dev/null @@ -1,87 +0,0 @@ -# Chrome Extension Support - -Electron supports a subset of the [Chrome Extensions API](https://developer.chrome.com/extensions/api_index), primarily to support DevTools extensions and Chromium-internal extensions, but it also happens to support some other extension capabilities. - -> **Note:** Electron does not support arbitrary Chrome extensions from the store, and it is a **non-goal** of the Electron project to be perfectly compatible with Chrome's implementation of Extensions. - -## Loading extensions - -Electron only supports loading unpacked extensions (i.e., `.crx` files do not work). Extensions are installed per-`session`. To load an extension, call [`ses.loadExtension`](session.md#sesloadextensionpath): - -```js -const { session } = require('electron') - -session.loadExtension('path/to/unpacked/extension').then(({ id }) => { - // ... -}) -``` - -Loaded extensions will not be automatically remembered across exits; if you do not call `loadExtension` when the app runs, the extension will not be loaded. - -Note that loading extensions is only supported in persistent sessions. Attempting to load an extension into an in-memory session will throw an error. - -See the [`session`](session.md) documentation for more information about loading, unloading, and querying active extensions. - -## Supported Extensions APIs - -We support the following extensions APIs, with some caveats. Other APIs may additionally be supported, but support for any APIs not listed here is provisional and may be removed. - -### `chrome.devtools.inspectedWindow` - -All features of this API are supported. - -### `chrome.devtools.network` - -All features of this API are supported. - -### `chrome.devtools.panels` - -All features of this API are supported. - -### `chrome.extension` - -The following properties of `chrome.extension` are supported: - -- `chrome.extension.lastError` - -The following methods of `chrome.extension` are supported: - -- `chrome.extension.getURL` -- `chrome.extension.getBackgroundPage` - -### `chrome.runtime` - -The following properties of `chrome.runtime` are supported: - -- `chrome.runtime.lastError` -- `chrome.runtime.id` - -The following methods of `chrome.runtime` are supported: - -- `chrome.runtime.getBackgroundPage` -- `chrome.runtime.getManifest` -- `chrome.runtime.getURL` -- `chrome.runtime.connect` -- `chrome.runtime.sendMessage` - -The following events of `chrome.runtime` are supported: - -- `chrome.runtime.onStartup` -- `chrome.runtime.onInstalled` -- `chrome.runtime.onSuspend` -- `chrome.runtime.onSuspendCanceled` -- `chrome.runtime.onConnect` -- `chrome.runtime.onMessage` - -### `chrome.storage` - -Only `chrome.storage.local` is supported; `chrome.storage.sync` and `chrome.storage.managed` are not. - -### `chrome.tabs` - -The following methods of `chrome.tabs` are supported: - -- `chrome.tabs.sendMessage` -- `chrome.tabs.executeScript` - -> **Note:** In Chrome, passing `-1` as a tab ID signifies the "currently active tab". Since Electron has no such concept, passing `-1` as a tab ID is not supported and will raise an error. diff --git a/content/current/zh-CN/docs/api/message-channel-main.md b/content/current/zh-CN/docs/api/message-channel-main.md deleted file mode 100644 index 6550a40e4b7fd..0000000000000 --- a/content/current/zh-CN/docs/api/message-channel-main.md +++ /dev/null @@ -1,26 +0,0 @@ -# MessageChannelMain - -`MessageChannelMain` is the main-process-side equivalent of the DOM [`MessageChannel`][] object. Its singular function is to create a pair of connected [`MessagePortMain`](message-port-main.md) objects. - -See the [Channel Messaging API](https://developer.mozilla.org/en-US/docs/Web/API/Channel_Messaging_API) documentation for more information on using channel messaging. - -## Class: MessageChannelMain - -进程:[主进程](../glossary.md#main-process) - -示例: -```js -const { port1, port2 } = new MessageChannelMain() -w.webContents.postMessage('port', null, [port2]) -port1.postMessage({ some: 'message' }) -``` - -### 实例属性 - -#### `channel.port1` - -A [`MessagePortMain`](message-port-main.md) property. - -#### `channel.port2` - -A [`MessagePortMain`](message-port-main.md) property. diff --git a/content/current/zh-CN/docs/api/message-port-main.md b/content/current/zh-CN/docs/api/message-port-main.md deleted file mode 100644 index 0df44a5466e98..0000000000000 --- a/content/current/zh-CN/docs/api/message-port-main.md +++ /dev/null @@ -1,44 +0,0 @@ -# MessagePortMain - -`MessagePortMain` is the main-process-side equivalent of the DOM [`MessagePort`][] object. It behaves similarly to the DOM version, with the exception that it uses the Node.js `EventEmitter` event system, instead of the DOM `EventTarget` system. This means you should use `port.on('message', ...)` to listen for events, instead of `port.onmessage = ...` or `port.addEventListener('message', ...)` - -See the [Channel Messaging API](https://developer.mozilla.org/en-US/docs/Web/API/Channel_Messaging_API) documentation for more information on using channel messaging. - -`MessagePortMain` is an \[EventEmitter\]\[event-emitter\]. - -## Class: MessagePortMain - -进程:[主进程](../glossary.md#main-process) - -### 实例方法 - -#### `port.postMessage(message, [transfer])` - -* `message` any -* `transfer` MessagePortMain[] (optional) - -Sends a message from the port, and optionally, transfers ownership of objects to other browsing contexts. - -#### `port.start()` - -Starts the sending of messages queued on the port. Messages will be queued until this method is called. - -#### `port.close()` - -Disconnects the port, so it is no longer active. - -### 实例事件 - -#### Event: 'message' - -返回: - -* `messageEvent` Object - * `data` any - * `ports` MessagePortMain[] - -Emitted when a MessagePortMain object receives a message. - -#### 事件: 'close' - -Emitted when the remote end of a MessagePortMain object becomes disconnected. diff --git a/content/current/zh-CN/docs/api/service-workers.md b/content/current/zh-CN/docs/api/service-workers.md deleted file mode 100644 index b073d143c24a1..0000000000000 --- a/content/current/zh-CN/docs/api/service-workers.md +++ /dev/null @@ -1,61 +0,0 @@ -## Class: ServiceWorkers - -> Query and receive events from a sessions active service workers. - -进程:[主进程](../glossary.md#main-process) - -Instances of the `ServiceWorkers` class are accessed by using `serviceWorkers` property of a `Session`. - -例如: - -```javascript -const { session } = require('electron') - -// Get all service workers. -console.log(session.defaultSession.serviceWorkers.getAllRunning()) - -// Handle logs and get service worker info -session.defaultSession.serviceWorkers.on('console-message', (event, messageDetails) => { - console.log( - 'Got service worker message', - messageDetails, - 'from', - session.defaultSession.serviceWorkers.getFromVersionID(messageDetails.versionId) - ) -}) -``` - -### 实例事件 - -The following events are available on instances of `ServiceWorkers`: - -#### Event: 'console-message' - -返回: - -* `event` Event -* `messageDetails` Object - Information about the console message - * `message` String - The actual console message - * `versionId` Number - The version ID of the service worker that sent the log message - * `source` String - The type of source for this message. Can be `javascript`, `xml`, `network`, `console-api`, `storage`, `app-cache`, `rendering`, `security`, `deprecation`, `worker`, `violation`, `intervention`, `recommendation` or `other`. - * `level` Number - The log level, from 0 to 3. In order it matches `verbose`, `info`, `warning` and `error`. - * `sourceUrl` String - The URL the message came from - * `lineNumber` Number - The line number of the source that triggered this console message - -Emitted when a service worker logs something to the console. - -### 实例方法 - -The following methods are available on instances of `ServiceWorkers`: - -#### `serviceWorkers.getAllRunning()` - -Returns `Record<Number, ServiceWorkerInfo>` - A [ServiceWorkerInfo](structures/service-worker-info.md) object where the keys are the service worker version ID and the values are the information about that service worker. - -#### `serviceWorkers.getFromVersionID(versionId)` - -* `versionId` Number - -Returns [`ServiceWorkerInfo`](structures/service-worker-info.md) - Information about this service worker - -If the service worker does not exist or is not running this method will throw an exception. diff --git a/content/current/zh-CN/docs/api/structures/extension.md b/content/current/zh-CN/docs/api/structures/extension.md deleted file mode 100644 index df9e77c202699..0000000000000 --- a/content/current/zh-CN/docs/api/structures/extension.md +++ /dev/null @@ -1,8 +0,0 @@ -# Extension Object - -* `id` String -* `manifest` any - Copy of the [extension's manifest data](https://developer.chrome.com/extensions/manifest). -* `name` String -* `path` String - The extension's file path. -* `version` String -* `url` String - The extension's `chrome-extension://` URL. diff --git a/content/current/zh-CN/docs/api/structures/post-body.md b/content/current/zh-CN/docs/api/structures/post-body.md deleted file mode 100644 index 75d01bc891e2a..0000000000000 --- a/content/current/zh-CN/docs/api/structures/post-body.md +++ /dev/null @@ -1,19 +0,0 @@ -# PostBody Object - -* `data` Array<[PostData](./post-data.md)> - The post data to be sent to the new window. -* `contentType` String - The `content-type` header used for the data. One of `application/x-www-form-urlencoded` or `multipart/form-data`. Corresponds to the `enctype` attribute of the submitted HTML form. -* `boundary` String (optional) - The boundary used to separate multiple parts of the message. Only valid when `contentType` is `multipart/form-data`. - -Note that keys starting with `--` are not currently supported. For example, this will errantly submit as `multipart/form-data` when `nativeWindowOpen` is set to `false` in webPreferences: - -```html -<form - target="_blank" - method="POST" - enctype="application/x-www-form-urlencoded" - action="https://postman-echo.com/post" -> - <input type="text" name="--theKey"> - <input type="submit"> -</form> -``` diff --git a/content/current/zh-CN/docs/api/structures/post-data.md b/content/current/zh-CN/docs/api/structures/post-data.md deleted file mode 100644 index 0b80a9957b975..0000000000000 --- a/content/current/zh-CN/docs/api/structures/post-data.md +++ /dev/null @@ -1,12 +0,0 @@ -# PostData Object - -* `type` String - One of the following: - * `rawData` - The data is available as a `Buffer`, in the `rawData` field. - * `file` - The object represents a file. The `filePath`, `offset`, `length` and `modificationTime` fields will be used to describe the file. - * `blob` - The object represents a `Blob`. The `blobUUID` field will be used to describe the `Blob`. -* `bytes` String (optional) - The raw bytes of the post data in a `Buffer`. Required for the `rawData` type. -* `filePath` String (optional) - The path of the file being uploaded. Required for the `file` type. -* `blobUUID` String (optional) - The `UUID` of the `Blob` being uploaded. Required for the `blob` type. -* `offset` Integer (optional) - The offset from the beginning of the file being uploaded, in bytes. Only valid for `file` types. -* `length` Integer (optional) - The length of the file being uploaded, in bytes. If set to `-1`, the whole file will be uploaded. Only valid for `file` types. -* `modificationTime` Double (optional) - The modification time of the file represented by a double, which is the number of seconds since the `UNIX Epoch` (Jan 1, 1970). Only valid for `file` types. diff --git a/content/current/zh-CN/docs/api/structures/service-worker-info.md b/content/current/zh-CN/docs/api/structures/service-worker-info.md deleted file mode 100644 index 578ef347744a2..0000000000000 --- a/content/current/zh-CN/docs/api/structures/service-worker-info.md +++ /dev/null @@ -1,5 +0,0 @@ -# ServiceWorkerInfo Object - -* `scriptUrl` String - The full URL to the script that this service worker runs -* `scope` String - The base URL that this service worker is active for. -* `renderProcessId` Number - The virtual ID of the process that this service worker is running in. This is not an OS level PID. This aligns with the ID set used for `webContents.getProcessId()`. diff --git a/content/current/zh-CN/docs/api/touch-bar-other-items-proxy.md b/content/current/zh-CN/docs/api/touch-bar-other-items-proxy.md deleted file mode 100644 index 5eb60d1abf211..0000000000000 --- a/content/current/zh-CN/docs/api/touch-bar-other-items-proxy.md +++ /dev/null @@ -1,9 +0,0 @@ -## Class: TouchBarOtherItemsProxy - -> Instantiates a special "other items proxy", which nests TouchBar elements inherited from Chromium at the space indicated by the proxy. By default, this proxy is added to each TouchBar at the end of the input. For more information, see the AppKit docs on [NSTouchBarItemIdentifierOtherItemsProxy](https://developer.apple.com/documentation/appkit/nstouchbaritemidentifierotheritemsproxy) -> -> Note: Only one instance of this class can be added per TouchBar. - -Process: [Main](../tutorial/application-architecture.md#main-and-renderer-processes) - -### `new TouchBarOtherItemsProxy()` diff --git a/content/current/zh-TW/docs/api/extensions.md b/content/current/zh-TW/docs/api/extensions.md deleted file mode 100644 index 38fd90183978d..0000000000000 --- a/content/current/zh-TW/docs/api/extensions.md +++ /dev/null @@ -1,87 +0,0 @@ -# Chrome Extension Support - -Electron supports a subset of the [Chrome Extensions API](https://developer.chrome.com/extensions/api_index), primarily to support DevTools extensions and Chromium-internal extensions, but it also happens to support some other extension capabilities. - -> **Note:** Electron does not support arbitrary Chrome extensions from the store, and it is a **non-goal** of the Electron project to be perfectly compatible with Chrome's implementation of Extensions. - -## Loading extensions - -Electron only supports loading unpacked extensions (i.e., `.crx` files do not work). Extensions are installed per-`session`. To load an extension, call [`ses.loadExtension`](session.md#sesloadextensionpath): - -```js -const { session } = require('electron') - -session.loadExtension('path/to/unpacked/extension').then(({ id }) => { - // ... -}) -``` - -Loaded extensions will not be automatically remembered across exits; if you do not call `loadExtension` when the app runs, the extension will not be loaded. - -Note that loading extensions is only supported in persistent sessions. Attempting to load an extension into an in-memory session will throw an error. - -See the [`session`](session.md) documentation for more information about loading, unloading, and querying active extensions. - -## Supported Extensions APIs - -We support the following extensions APIs, with some caveats. Other APIs may additionally be supported, but support for any APIs not listed here is provisional and may be removed. - -### `chrome.devtools.inspectedWindow` - -All features of this API are supported. - -### `chrome.devtools.network` - -All features of this API are supported. - -### `chrome.devtools.panels` - -All features of this API are supported. - -### `chrome.extension` - -The following properties of `chrome.extension` are supported: - -- `chrome.extension.lastError` - -The following methods of `chrome.extension` are supported: - -- `chrome.extension.getURL` -- `chrome.extension.getBackgroundPage` - -### `chrome.runtime` - -The following properties of `chrome.runtime` are supported: - -- `chrome.runtime.lastError` -- `chrome.runtime.id` - -The following methods of `chrome.runtime` are supported: - -- `chrome.runtime.getBackgroundPage` -- `chrome.runtime.getManifest` -- `chrome.runtime.getURL` -- `chrome.runtime.connect` -- `chrome.runtime.sendMessage` - -The following events of `chrome.runtime` are supported: - -- `chrome.runtime.onStartup` -- `chrome.runtime.onInstalled` -- `chrome.runtime.onSuspend` -- `chrome.runtime.onSuspendCanceled` -- `chrome.runtime.onConnect` -- `chrome.runtime.onMessage` - -### `chrome.storage` - -Only `chrome.storage.local` is supported; `chrome.storage.sync` and `chrome.storage.managed` are not. - -### `chrome.tabs` - -The following methods of `chrome.tabs` are supported: - -- `chrome.tabs.sendMessage` -- `chrome.tabs.executeScript` - -> **Note:** In Chrome, passing `-1` as a tab ID signifies the "currently active tab". Since Electron has no such concept, passing `-1` as a tab ID is not supported and will raise an error. diff --git a/content/current/zh-TW/docs/api/message-channel-main.md b/content/current/zh-TW/docs/api/message-channel-main.md deleted file mode 100644 index 9871605ed3355..0000000000000 --- a/content/current/zh-TW/docs/api/message-channel-main.md +++ /dev/null @@ -1,26 +0,0 @@ -# MessageChannelMain - -`MessageChannelMain` is the main-process-side equivalent of the DOM [`MessageChannel`][] object. Its singular function is to create a pair of connected [`MessagePortMain`](message-port-main.md) objects. - -See the [Channel Messaging API](https://developer.mozilla.org/en-US/docs/Web/API/Channel_Messaging_API) documentation for more information on using channel messaging. - -## Class: MessageChannelMain - -處理序: [主處理序](../glossary.md#main-process) - -範例: -```js -const { port1, port2 } = new MessageChannelMain() -w.webContents.postMessage('port', null, [port2]) -port1.postMessage({ some: 'message' }) -``` - -### 物件屬性 - -#### `channel.port1` - -A [`MessagePortMain`](message-port-main.md) property. - -#### `channel.port2` - -A [`MessagePortMain`](message-port-main.md) property. diff --git a/content/current/zh-TW/docs/api/message-port-main.md b/content/current/zh-TW/docs/api/message-port-main.md deleted file mode 100644 index 58af0bf250a26..0000000000000 --- a/content/current/zh-TW/docs/api/message-port-main.md +++ /dev/null @@ -1,44 +0,0 @@ -# MessagePortMain - -`MessagePortMain` is the main-process-side equivalent of the DOM [`MessagePort`][] object. It behaves similarly to the DOM version, with the exception that it uses the Node.js `EventEmitter` event system, instead of the DOM `EventTarget` system. This means you should use `port.on('message', ...)` to listen for events, instead of `port.onmessage = ...` or `port.addEventListener('message', ...)` - -See the [Channel Messaging API](https://developer.mozilla.org/en-US/docs/Web/API/Channel_Messaging_API) documentation for more information on using channel messaging. - -`MessagePortMain` is an \[EventEmitter\]\[event-emitter\]. - -## Class: MessagePortMain - -處理序: [主處理序](../glossary.md#main-process) - -### 物件方法 - -#### `port.postMessage(message, [transfer])` - -* `message` any -* `transfer` MessagePortMain[] (optional) - -Sends a message from the port, and optionally, transfers ownership of objects to other browsing contexts. - -#### `port.start()` - -Starts the sending of messages queued on the port. Messages will be queued until this method is called. - -#### `port.close()` - -Disconnects the port, so it is no longer active. - -### 物件事件 - -#### 事件: 'message' - -回傳: - -* `messageEvent` Object - * `data` any - * `ports` MessagePortMain[] - -Emitted when a MessagePortMain object receives a message. - -#### 事件: 'close' - -Emitted when the remote end of a MessagePortMain object becomes disconnected. diff --git a/content/current/zh-TW/docs/api/service-workers.md b/content/current/zh-TW/docs/api/service-workers.md deleted file mode 100644 index d1eae899d411b..0000000000000 --- a/content/current/zh-TW/docs/api/service-workers.md +++ /dev/null @@ -1,61 +0,0 @@ -## Class: ServiceWorkers - -> Query and receive events from a sessions active service workers. - -處理序: [主處理序](../glossary.md#main-process) - -Instances of the `ServiceWorkers` class are accessed by using `serviceWorkers` property of a `Session`. - -For example: - -```javascript -const { session } = require('electron') - -// Get all service workers. -console.log(session.defaultSession.serviceWorkers.getAllRunning()) - -// Handle logs and get service worker info -session.defaultSession.serviceWorkers.on('console-message', (event, messageDetails) => { - console.log( - 'Got service worker message', - messageDetails, - 'from', - session.defaultSession.serviceWorkers.getFromVersionID(messageDetails.versionId) - ) -}) -``` - -### 物件事件 - -The following events are available on instances of `ServiceWorkers`: - -#### 事件: 'console-message' - -回傳: - -* `event` Event -* `messageDetails` Object - Information about the console message - * `message` String - The actual console message - * `versionId` Number - The version ID of the service worker that sent the log message - * `source` String - The type of source for this message. Can be `javascript`, `xml`, `network`, `console-api`, `storage`, `app-cache`, `rendering`, `security`, `deprecation`, `worker`, `violation`, `intervention`, `recommendation` or `other`. - * `level` Number - The log level, from 0 to 3. In order it matches `verbose`, `info`, `warning` and `error`. - * `sourceUrl` String - The URL the message came from - * `lineNumber` Number - The line number of the source that triggered this console message - -Emitted when a service worker logs something to the console. - -### 物件方法 - -The following methods are available on instances of `ServiceWorkers`: - -#### `serviceWorkers.getAllRunning()` - -Returns `Record<Number, ServiceWorkerInfo>` - A [ServiceWorkerInfo](structures/service-worker-info.md) object where the keys are the service worker version ID and the values are the information about that service worker. - -#### `serviceWorkers.getFromVersionID(versionId)` - -* `versionId` Number - -Returns [`ServiceWorkerInfo`](structures/service-worker-info.md) - Information about this service worker - -If the service worker does not exist or is not running this method will throw an exception. diff --git a/content/current/zh-TW/docs/api/structures/extension.md b/content/current/zh-TW/docs/api/structures/extension.md deleted file mode 100644 index df9e77c202699..0000000000000 --- a/content/current/zh-TW/docs/api/structures/extension.md +++ /dev/null @@ -1,8 +0,0 @@ -# Extension Object - -* `id` String -* `manifest` any - Copy of the [extension's manifest data](https://developer.chrome.com/extensions/manifest). -* `name` String -* `path` String - The extension's file path. -* `version` String -* `url` String - The extension's `chrome-extension://` URL. diff --git a/content/current/zh-TW/docs/api/structures/post-body.md b/content/current/zh-TW/docs/api/structures/post-body.md deleted file mode 100644 index 75d01bc891e2a..0000000000000 --- a/content/current/zh-TW/docs/api/structures/post-body.md +++ /dev/null @@ -1,19 +0,0 @@ -# PostBody Object - -* `data` Array<[PostData](./post-data.md)> - The post data to be sent to the new window. -* `contentType` String - The `content-type` header used for the data. One of `application/x-www-form-urlencoded` or `multipart/form-data`. Corresponds to the `enctype` attribute of the submitted HTML form. -* `boundary` String (optional) - The boundary used to separate multiple parts of the message. Only valid when `contentType` is `multipart/form-data`. - -Note that keys starting with `--` are not currently supported. For example, this will errantly submit as `multipart/form-data` when `nativeWindowOpen` is set to `false` in webPreferences: - -```html -<form - target="_blank" - method="POST" - enctype="application/x-www-form-urlencoded" - action="https://postman-echo.com/post" -> - <input type="text" name="--theKey"> - <input type="submit"> -</form> -``` diff --git a/content/current/zh-TW/docs/api/structures/post-data.md b/content/current/zh-TW/docs/api/structures/post-data.md deleted file mode 100644 index 0b80a9957b975..0000000000000 --- a/content/current/zh-TW/docs/api/structures/post-data.md +++ /dev/null @@ -1,12 +0,0 @@ -# PostData Object - -* `type` String - One of the following: - * `rawData` - The data is available as a `Buffer`, in the `rawData` field. - * `file` - The object represents a file. The `filePath`, `offset`, `length` and `modificationTime` fields will be used to describe the file. - * `blob` - The object represents a `Blob`. The `blobUUID` field will be used to describe the `Blob`. -* `bytes` String (optional) - The raw bytes of the post data in a `Buffer`. Required for the `rawData` type. -* `filePath` String (optional) - The path of the file being uploaded. Required for the `file` type. -* `blobUUID` String (optional) - The `UUID` of the `Blob` being uploaded. Required for the `blob` type. -* `offset` Integer (optional) - The offset from the beginning of the file being uploaded, in bytes. Only valid for `file` types. -* `length` Integer (optional) - The length of the file being uploaded, in bytes. If set to `-1`, the whole file will be uploaded. Only valid for `file` types. -* `modificationTime` Double (optional) - The modification time of the file represented by a double, which is the number of seconds since the `UNIX Epoch` (Jan 1, 1970). Only valid for `file` types. diff --git a/content/current/zh-TW/docs/api/structures/service-worker-info.md b/content/current/zh-TW/docs/api/structures/service-worker-info.md deleted file mode 100644 index 578ef347744a2..0000000000000 --- a/content/current/zh-TW/docs/api/structures/service-worker-info.md +++ /dev/null @@ -1,5 +0,0 @@ -# ServiceWorkerInfo Object - -* `scriptUrl` String - The full URL to the script that this service worker runs -* `scope` String - The base URL that this service worker is active for. -* `renderProcessId` Number - The virtual ID of the process that this service worker is running in. This is not an OS level PID. This aligns with the ID set used for `webContents.getProcessId()`. diff --git a/content/current/zh-TW/docs/api/touch-bar-other-items-proxy.md b/content/current/zh-TW/docs/api/touch-bar-other-items-proxy.md deleted file mode 100644 index 9ef2e8a58929e..0000000000000 --- a/content/current/zh-TW/docs/api/touch-bar-other-items-proxy.md +++ /dev/null @@ -1,9 +0,0 @@ -## Class: TouchBarOtherItemsProxy - -> Instantiates a special "other items proxy", which nests TouchBar elements inherited from Chromium at the space indicated by the proxy. By default, this proxy is added to each TouchBar at the end of the input. For more information, see the AppKit docs on [NSTouchBarItemIdentifierOtherItemsProxy](https://developer.apple.com/documentation/appkit/nstouchbaritemidentifierotheritemsproxy) -> -> Note: Only one instance of this class can be added per TouchBar. - -處理序: [主處理序](../tutorial/application-architecture.md#main-and-renderer-processes) - -### `new TouchBarOtherItemsProxy()` diff --git a/lib/parsers/docs-parser.ts b/lib/parsers/docs-parser.ts index 4f2c9cd1bc3fb..abc71da9a7825 100644 --- a/lib/parsers/docs-parser.ts +++ b/lib/parsers/docs-parser.ts @@ -56,7 +56,7 @@ export async function parseFile(file: IParseFile, ids: Record<string, string>) { runBefore: [plaintextFix, bashFix, fiddleUrls], highlight: { ignoreMissing: true, - } + }, }) const $ = cheerio.load(parsed.content || '') file.title = diff --git a/package.json b/package.json index 03406c8c854f9..3e21ccc42f10f 100644 --- a/package.json +++ b/package.json @@ -73,8 +73,8 @@ "upload-crowdin-glossary": "ts-node script/upload-crowdin-glossary.ts", "automerge": "ts-node ./script/automerge.ts" }, - "electronLatestStableTag": "v8.2.3", - "electronMasterBranchCommit": "8262f24fd852bdf3f5992e7f8622a35ab9c798df", + "electronLatestStableTag": "v8.2.5", + "electronMasterBranchCommit": "85fae6796620a860e795e8b6c552fb24c4691b0c", "engines": { "node": ">=10" }, @@ -88,4 +88,4 @@ "7-2-x", "9-x-y" ] -} +} \ No newline at end of file diff --git a/stats.json b/stats.json index 00b9272770a2c..e1cd65b4692f3 100644 --- a/stats.json +++ b/stats.json @@ -3,10 +3,10 @@ "name": "Arabic", "code": "ar", "phrases": "65630", - "translated": "7729", + "translated": "7730", "approved": "5721", "words": "630667", - "words_translated": "49971", + "words_translated": "49978", "words_approved": "36689", "translated_progress": 7, "approved_progress": 5, @@ -29,27 +29,27 @@ "name": "Chinese Simplified", "code": "zh-CN", "phrases": "65630", - "translated": "41904", + "translated": "41924", "approved": "33983", "words": "630667", - "words_translated": "355835", + "words_translated": "356175", "words_approved": "289363", "translated_progress": 56, "approved_progress": 45, - "qa_issues": 197 + "qa_issues": 199 }, { "name": "Chinese Traditional", "code": "zh-TW", "phrases": "65630", - "translated": "20468", + "translated": "20548", "approved": "16428", "words": "630667", - "words_translated": "97853", + "words_translated": "98491", "words_approved": "77828", "translated_progress": 15, "approved_progress": 12, - "qa_issues": 60 + "qa_issues": 65 }, { "name": "Czech", @@ -94,27 +94,27 @@ "name": "French", "code": "fr", "phrases": "65630", - "translated": "43576", + "translated": "43621", "approved": "35015", "words": "630667", - "words_translated": "368427", + "words_translated": "369031", "words_approved": "293822", "translated_progress": 58, "approved_progress": 46, - "qa_issues": 2099 + "qa_issues": 2106 }, { "name": "German", "code": "de", "phrases": "65630", - "translated": "23308", + "translated": "23440", "approved": "18435", "words": "630667", - "words_translated": "134197", + "words_translated": "135483", "words_approved": "104133", "translated_progress": 21, "approved_progress": 16, - "qa_issues": 1515 + "qa_issues": 1567 }, { "name": "Hebrew", @@ -159,79 +159,79 @@ "name": "Italian", "code": "it", "phrases": "65630", - "translated": "23924", + "translated": "23932", "approved": "19327", "words": "630667", - "words_translated": "172650", + "words_translated": "172736", "words_approved": "141891", "translated_progress": 27, "approved_progress": 22, - "qa_issues": 1343 + "qa_issues": 1346 }, { "name": "Japanese", "code": "ja", "phrases": "65630", - "translated": "60466", + "translated": "63366", "approved": "45634", "words": "630667", - "words_translated": "566804", + "words_translated": "600021", "words_approved": "415208", - "translated_progress": 89, + "translated_progress": 95, "approved_progress": 65, - "qa_issues": 338 + "qa_issues": 368 }, { "name": "Korean", "code": "ko", "phrases": "65630", - "translated": "28266", + "translated": "28854", "approved": "21807", "words": "630667", - "words_translated": "243071", + "words_translated": "252769", "words_approved": "180680", - "translated_progress": 38, + "translated_progress": 40, "approved_progress": 28, - "qa_issues": 2411 + "qa_issues": 2450 }, { "name": "Persian", "code": "fa", "phrases": "65630", - "translated": "4699", + "translated": "4904", "approved": "3074", "words": "630667", - "words_translated": "19790", + "words_translated": "22900", "words_approved": "12966", "translated_progress": 3, "approved_progress": 2, - "qa_issues": 33 + "qa_issues": 34 }, { "name": "Polish", "code": "pl", "phrases": "65630", - "translated": "21975", - "approved": "18465", + "translated": "21989", + "approved": "18470", "words": "630667", - "words_translated": "104886", - "words_approved": "86772", + "words_translated": "104986", + "words_approved": "86793", "translated_progress": 16, "approved_progress": 13, - "qa_issues": 851 + "qa_issues": 853 }, { "name": "Portuguese, Brazilian", "code": "pt-BR", "phrases": "65630", - "translated": "22020", + "translated": "22423", "approved": "17323", "words": "630667", - "words_translated": "158005", + "words_translated": "164805", "words_approved": "122554", - "translated_progress": 25, + "translated_progress": 26, "approved_progress": 19, - "qa_issues": 747 + "qa_issues": 773 }, { "name": "Romanian", @@ -250,27 +250,27 @@ "name": "Russian", "code": "ru", "phrases": "65630", - "translated": "40881", + "translated": "40882", "approved": "35120", "words": "630667", - "words_translated": "337179", + "words_translated": "337198", "words_approved": "288805", "translated_progress": 53, "approved_progress": 45, - "qa_issues": 1822 + "qa_issues": 1823 }, { "name": "Spanish", "code": "es-ES", "phrases": "65630", - "translated": "48839", + "translated": "48948", "approved": "40246", "words": "630667", - "words_translated": "432624", + "words_translated": "433670", "words_approved": "356240", "translated_progress": 68, "approved_progress": 56, - "qa_issues": 2936 + "qa_issues": 2972 }, { "name": "Tagalog", @@ -289,40 +289,40 @@ "name": "Thai", "code": "th", "phrases": "65630", - "translated": "6464", + "translated": "6472", "approved": "4930", "words": "630667", - "words_translated": "34158", + "words_translated": "34233", "words_approved": "24753", "translated_progress": 5, "approved_progress": 3, - "qa_issues": 838 + "qa_issues": 841 }, { "name": "Turkish", "code": "tr", "phrases": "65630", - "translated": "34726", + "translated": "34772", "approved": "28230", "words": "630667", - "words_translated": "269186", + "words_translated": "269599", "words_approved": "220282", "translated_progress": 42, "approved_progress": 34, - "qa_issues": 2301 + "qa_issues": 2321 }, { "name": "Ukrainian", "code": "uk", "phrases": "65630", - "translated": "20557", + "translated": "21089", "approved": "17005", "words": "630667", - "words_translated": "125462", + "words_translated": "128842", "words_approved": "106785", - "translated_progress": 19, + "translated_progress": 20, "approved_progress": 16, - "qa_issues": 1050 + "qa_issues": 1154 }, { "name": "Vietnamese", diff --git a/wordcount.md b/wordcount.md index 7d8869d7489d7..57cfc39c20110 100644 --- a/wordcount.md +++ b/wordcount.md @@ -4,25 +4,25 @@ Stat | Value ---- | ----- -total files | 272 -total words | 262619 -unique words | 12504 -average words per file | 965 +total files | 274 +total words | 263522 +unique words | 12521 +average words per file | 961 ## Blog English Stat | Value ---- | ----- total files | 66 -total words | 46379 -unique words | 5987 -average words per file | 702 +total words | 46428 +unique words | 5992 +average words per file | 703 ## All Languages Stat | Value ---- | ----- -total files | 7259 -total words | 5448719 -unique words | 93832 -average words per file | 750 +total files | 7261 +total words | 5454339 +unique words | 91029 +average words per file | 751