Add getRegisteredPlugins, plugin manager panel in test app

This commit is contained in:
2026-04-18 20:24:54 +10:00
parent 93dbef6a59
commit c6d3d4cbe5
7 changed files with 247 additions and 5 deletions

View File

@@ -114,6 +114,19 @@ export declare class PluginRegistry {
clearLogs(pluginId?: string): void;
/** Get the public exports of a loaded plugin. */
getPluginExports(pluginId: string): unknown;
/**
* Returns metadata for all currently registered plugins.
* Useful for displaying a plugin directory / manager UI.
*/
getRegisteredPlugins(): Array<{
id: string;
name: string;
version: string;
commandCount: number;
interceptorCount: number;
themeCount: number;
hasSettings: boolean;
}>;
/** Unload the current plugin instance and load a new one in-place. */
reloadPlugin(pluginId: string, newPlugin: Plugin, newContext: PluginContext): Promise<void>;
/** Unload all plugins and clear all registry state. */