Function: realmPlugin()
realmPlugin<
Params
>(plugin
): (params
?) =>RealmPlugin
A function that creates an editor plugin.
Type parameters
Type parameter | Description |
---|---|
Params | The parameters for the plugin. |
Parameters
Parameter | Type | Description |
---|---|---|
plugin | object | - |
plugin.init ? | (realm , params ?) => void | Called when the MDXEditor component is mounted and the plugin is initialized. |
plugin.postInit ? | (realm , params ?) => void | Called after the MDXEditor component is mounted and all plugins are initialized. |
plugin.update ? | (realm , params ?) => void | Called on each re-render. Use this to update the realm with updated property values. |
Returns
Function
Parameters
Parameter | Type |
---|---|
params ? | Params |