plugins
namespace pluginsFunctions
disable(id: string): void
Disables a plugin and stops it.
enable(id: string): void | Promise<void>
Enables a plugin and starts it.
get(id: string): AddonHandle | undefined
Reads one installed plugin by id.
getAll(): AddonHandle[]
Lists every installed plugin.
install(url: string, digest?: string): Promise<AddonHandle | undefined>
Installs a plugin from its manifest URL.
isEnabled(id: string): boolean
Reports whether a plugin is enabled.
reload(id: string, bundle: string, manifest: PushedManifest, bytecode?: string): Promise<ReloadResult>
Swaps a plugin's bundle in place, keeping its enabled state.
start(id: string): void | Promise<void>
Starts a plugin without changing its enabled state.
stop(id: string): void | Promise<void>
Stops a running plugin without changing its enabled state.
toggle(id: string): void
Enables a disabled plugin, or disables an enabled one.
uninstall(id: string): Promise<void>
Stops and removes an installed plugin.
update(id: string): Promise<boolean>
Checks for updates, then applies this plugin's pending update.
Returns
Whether the plugin now runs a newer version.
Types
The outcome of an addon reload: success, or failure carrying the recorded error.
Variables
entities: ReadonlyMap<PropertyKey, AddonHandle>
Every installed plugin, keyed by id.
errors: ReadonlyMap<PropertyKey, Error>
The error each plugin that failed to load or start threw, keyed by id.
startDurations: ReadonlyMap<string, number>
How long each plugin's last start took, in milliseconds, keyed by id.