plugin.d.ts 439 B

1234567891011
  1. import type { Config, PluginCreator } from './types/config'
  2. type Plugin = {
  3. withOptions<T>(
  4. plugin: (options: T) => PluginCreator,
  5. config?: (options: T) => Partial<Config>
  6. ): { (options: T): { handler: PluginCreator; config?: Partial<Config> }; __isOptionsFunction: true }
  7. (plugin: PluginCreator, config?: Partial<Config>): { handler: PluginCreator; config?: Partial<Config> }
  8. }
  9. declare const plugin: Plugin
  10. export = plugin