Skip to content

WaitForPluginParams<TPlugin>

Parameters for waitForPlugin.

Import:

import type { WaitForPluginParams } from '@mnaoumov/obsidian-lib/plugin/plugin-instance';

Signature:

export interface WaitForPluginParams<TPlugin extends Plugin = Plugin> extends GetPluginAvailabilityParams<TPlugin>

Extends: GetPluginAvailabilityParams<TPlugin>

Properties

PropertyTypeDescription
abortSignal?AbortSignalEnds the wait early; the promise rejects with the signal's reason.
appAppThe Obsidian app instance.
(Inherited from GetPluginAvailabilityParams)
component?ComponentA component whose unload ends the wait, rejecting the promise. Pass the waiting plugin, or the component that will use the instance, so a wait never outlives its consumer.
isPlugin?(plugin: Plugin) => plugin is TPluginVerifies that the running instance is the shape the caller uses. Without it, TPlugin is an assertion nothing checks.
(Inherited from GetPluginAvailabilityParams)
minPluginVersion?stringThe oldest release of the plugin the caller works with, compared with its manifest.version. This is a plugin RELEASE, never an API contract version: a provider publishing a versioned contract is reached through watchPluginApi's apiVersionRange instead.
(Inherited from GetPluginAvailabilityParams)
pluginIdstringThe manifest.id of the plugin.
(Inherited from GetPluginAvailabilityParams)
timeoutInMilliseconds?numberHow long to wait before rejecting with a PluginInstanceUnavailableError.

Links to this page: