Skip to content
This repository was archived by the owner on Jun 16, 2022. It is now read-only.

Latest commit

 

History

History
91 lines (60 loc) · 1.47 KB

File metadata and controls

91 lines (60 loc) · 1.47 KB

Plugins

These methods are accessible through profile.plugins() which exposes a PluginRepository instance.

Get a list of all plugins

profile.plugins().all();

Get the first listed plugin

profile.plugins().first();

Get the last listed plugin

profile.plugins().last();

Get all data keys

profile.plugins().keys();

Get all data values

profile.plugins().values();

Register a new plugin

profile.plugins().push(stubPlugin);

Restore previously created data

profile.plugins().fill({ ["@hello/world"]: stubPlugin });

Find the plugin for a given Id

profile.plugins().findById("@hello/world");

Forget a plugin using its Id

profile.plugins().forget("@hello/world");

Forget all plugins (Use with caution!)

profile.plugins().flush();

Get the count of stored plugins

profile.plugins().count();

Registry

These methods are accessible through profile.plugins().registry() which exposes a PluginRegistry instance.

Get a list of registered plugins

profile.plugins().registry().all();

Get the size of a specific registry plugin

profile.plugins().registry().size(registryPlugin);

Get the download count of a specific registry plugin

profile.plugins().registry().downloads(registryPlugin);