Skip to content
Snippets Groups Projects

Resolve "[MIN-282] Plugins: refresh plugin"

Merged Piotr Gawron requested to merge 215-min-282-plugins-refresh-plugin into development
3 files
+ 12
15
Compare changes
  • Side-by-side
  • Inline
Files
3
@@ -105,15 +105,19 @@ export const useLoadPlugin = ({
};
const handleReloadPlugin = async (): Promise<void> => {
handleUnloadPlugin();
PluginsManager.removePluginContent({ hash });
PluginsManager.unloadActivePlugin(hash);
PluginsEventBus.dispatchEvent('onPluginUnload', { hash });
await handleLoadPlugin();
};
const togglePlugin = (): void => {
const togglePlugin = async (): Promise<void> => {
if (isPluginActive) {
handleUnloadPlugin();
} else {
handleLoadPlugin();
await handleLoadPlugin();
}
};
Loading