Interface PluginDependencyDeclaration

Hierarchy

  • PluginDependencyDeclaration

Properties

loadedBefore: boolean

Whether or not the dependency must be loaded before the plugin, or whether it can be "lazy loaded" and simply assigned at any point.

This is useful for allowing circular dependencies:

        <-- depends on -->
/====================\
// \\
._pluginService? V
MyPluginAPI MyPluginService
^ ._pluginApi
\\ //
\=====================/

In this example, MyPluginApi depends on MyPluginService and MyPluginService depends on MyPluginApi. Normally this would fail, however while MyPluginAPI depends on MyPluginService, it doesn't necessarily have to be loaded after it, it can wait for it to be loaded.

Default

true

optional: boolean

Whether or not this dependency is optional, and the plugin can work either partially or differently without it.

Default

false

pluginId: string

The id of the plugin that a plugin depends on to function fully.

version: string

The acceptable version glob of the plugin that a plugin depends on.

Note: if optional is enabled, the dependency won't be available to the plugin (at least through the Plugin.getDependency interface) if the loaded version doesn't match this version glob.

Default

Generated using TypeDoc