index.d.ts 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. import { Extension, LoadExtensionOptions, Session } from 'electron';
  2. export interface ExtensionReference {
  3. /**
  4. * Extension ID
  5. */
  6. id: string;
  7. }
  8. export interface InstallExtensionOptions {
  9. /**
  10. * Ignore whether the extension is already downloaded and redownload every time
  11. */
  12. forceDownload?: boolean;
  13. /**
  14. * Options passed to session.loadExtension
  15. */
  16. loadExtensionOptions?: LoadExtensionOptions;
  17. /**
  18. * Optionally specify the session to install devtools into, by default devtools
  19. * will be installed into the "defaultSession". See the Electron Session docs
  20. * for more info.
  21. *
  22. * https://electronjs.org/docs/api/session
  23. */
  24. session?: Session;
  25. }
  26. /**
  27. * @param extensionReference Extension or extensions to install
  28. * @param options Installation options
  29. * @returns A promise resolving with the name or names of the extensions installed
  30. */
  31. export declare function installExtension(extensionReference: Array<ExtensionReference | string>, options?: InstallExtensionOptions): Promise<Extension[]>;
  32. export declare function installExtension(extensionReference: ExtensionReference | string, options?: InstallExtensionOptions): Promise<Extension>;
  33. export default installExtension;
  34. export declare const EMBER_INSPECTOR: ExtensionReference;
  35. export declare const REACT_DEVELOPER_TOOLS: ExtensionReference;
  36. export declare const BACKBONE_DEBUGGER: ExtensionReference;
  37. export declare const JQUERY_DEBUGGER: ExtensionReference;
  38. export declare const VUEJS_DEVTOOLS: ExtensionReference;
  39. export declare const VUEJS_DEVTOOLS_BETA: ExtensionReference;
  40. export declare const REDUX_DEVTOOLS: ExtensionReference;
  41. export declare const MOBX_DEVTOOLS: ExtensionReference;