refactor: prevent consistent early exception (#24191)
* refactor: prevent consistent early exception * Use _linkedBinding where possible * Remove dead electronBinding
This commit is contained in:
parent
4c77fe318d
commit
659e79fc08
78 changed files with 134 additions and 145 deletions
18
typings/internal-ambient.d.ts
vendored
18
typings/internal-ambient.d.ts
vendored
|
@ -89,21 +89,17 @@ declare namespace NodeJS {
|
|||
}
|
||||
|
||||
interface Process {
|
||||
/**
|
||||
* DO NOT USE DIRECTLY, USE process.electronBinding
|
||||
*/
|
||||
_linkedBinding(name: string): any;
|
||||
electronBinding(name: string): any;
|
||||
electronBinding(name: 'features'): FeaturesBinding;
|
||||
electronBinding(name: 'ipc'): { ipc: IpcRendererBinding };
|
||||
electronBinding(name: 'v8_util'): V8UtilBinding;
|
||||
electronBinding(name: 'app'): { app: Electron.App, App: Function };
|
||||
electronBinding(name: 'command_line'): Electron.CommandLine;
|
||||
electronBinding(name: 'desktop_capturer'): {
|
||||
_linkedBinding(name: 'electron_renderer_ipc'): { ipc: IpcRendererBinding };
|
||||
_linkedBinding(name: 'electron_common_v8_util'): V8UtilBinding;
|
||||
_linkedBinding(name: 'electron_common_features'): FeaturesBinding;
|
||||
_linkedBinding(name: 'electron_browser_app'): { app: Electron.App, App: Function };
|
||||
_linkedBinding(name: 'electron_common_command_line'): Electron.CommandLine;
|
||||
_linkedBinding(name: 'electron_browser_desktop_capturer'): {
|
||||
createDesktopCapturer(): ElectronInternal.DesktopCapturer;
|
||||
getMediaSourceIdForWebContents(requestWebContentsId: number, webContentsId: number): string;
|
||||
};
|
||||
electronBinding(name: 'net'): {
|
||||
_linkedBinding(name: 'electron_browser_net'): {
|
||||
isValidHeaderName: (headerName: string) => boolean;
|
||||
isValidHeaderValue: (headerValue: string) => boolean;
|
||||
Net: any;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue