feat: add plugin interface

This commit is contained in:
Hufe921
2023-06-25 21:33:43 +08:00
committed by Hufe
parent ca28454049
commit ad0bb32b70
3 changed files with 28 additions and 1 deletions
+5
View File
@@ -0,0 +1,5 @@
import Editor from '..'
export type PluginFunction<Options> = (editor: Editor, options?: Options) => any;
export type UsePlugin = <Options>(pluginFunction: PluginFunction<Options>, options?: Options) => void;