Plugin
The Plugin System provides a modular architecture that allows the Wizard framework to be extended with additional functionality through dynamically loaded plugins.
DefinePlugin
Parameters:Name | Type | Default |
---|---|---|
plugin | Plugin<CommandMapping, Result, GlobalFlags> The plugin to define. |
Plugin
Advanced Usage
To seperate handlers from the plugin definition, you can use the definePlugin
utility function:
definePlugin.ts
import { definePlugin } from '@hyperse/wizard';
const deployPlugin = definePlugin({
name: 'deploy plugin',
localeMessages: helpMessages,
setup: (wizard, pluginCtx) => {
return wizard;
},
});
Last updated on