feat: enable native extensions support (#21814)

This commit is contained in:
Jeremy Apthorp 2020-02-03 14:01:10 -08:00 committed by GitHub
parent bdf65a75d0
commit a061c87e56
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
61 changed files with 1054 additions and 941 deletions

View file

@ -677,7 +677,7 @@ Returns `BrowserWindow | null` - The window that owns the given `browserView`. I
Returns `BrowserWindow` - The window with the given `id`.
#### `BrowserWindow.addExtension(path)`
#### `BrowserWindow.addExtension(path)` _Deprecated_
* `path` String
@ -688,7 +688,10 @@ The method will also not return if the extension's manifest is missing or incomp
**Note:** This API cannot be called before the `ready` event of the `app` module
is emitted.
#### `BrowserWindow.removeExtension(name)`
**Note:** This method is deprecated. Instead, use
[`ses.loadExtension(path)`](session.md#sesloadextensionpath).
#### `BrowserWindow.removeExtension(name)` _Deprecated_
* `name` String
@ -697,7 +700,10 @@ Remove a Chrome extension by name.
**Note:** This API cannot be called before the `ready` event of the `app` module
is emitted.
#### `BrowserWindow.getExtensions()`
**Note:** This method is deprecated. Instead, use
[`ses.removeExtension(extension_id)`](session.md#sesremoveextensionextensionid).
#### `BrowserWindow.getExtensions()` _Deprecated_
Returns `Record<String, ExtensionInfo>` - The keys are the extension names and each value is
an Object containing `name` and `version` properties.
@ -705,7 +711,10 @@ an Object containing `name` and `version` properties.
**Note:** This API cannot be called before the `ready` event of the `app` module
is emitted.
#### `BrowserWindow.addDevToolsExtension(path)`
**Note:** This method is deprecated. Instead, use
[`ses.getAllExtensions()`](session.md#sesgetallextensions).
#### `BrowserWindow.addDevToolsExtension(path)` _Deprecated_
* `path` String
@ -721,7 +730,10 @@ The method will also not return if the extension's manifest is missing or incomp
**Note:** This API cannot be called before the `ready` event of the `app` module
is emitted.
#### `BrowserWindow.removeDevToolsExtension(name)`
**Note:** This method is deprecated. Instead, use
[`ses.loadExtension(path)`](session.md#sesloadextensionpath).
#### `BrowserWindow.removeDevToolsExtension(name)` _Deprecated_
* `name` String
@ -730,7 +742,10 @@ Remove a DevTools extension by name.
**Note:** This API cannot be called before the `ready` event of the `app` module
is emitted.
#### `BrowserWindow.getDevToolsExtensions()`
**Note:** This method is deprecated. Instead, use
[`ses.removeExtension(extension_id)`](session.md#sesremoveextensionextensionid).
#### `BrowserWindow.getDevToolsExtensions()` _Deprecated_
Returns `Record<string, ExtensionInfo>` - The keys are the extension names and each value is
an Object containing `name` and `version` properties.
@ -747,6 +762,9 @@ console.log(installed)
**Note:** This API cannot be called before the `ready` event of the `app` module
is emitted.
**Note:** This method is deprecated. Instead, use
[`ses.getAllExtensions()`](session.md#sesgetallextensions).
### Instance Properties
Objects created with `new BrowserWindow` have the following properties: