Plugin.registerView method
Plugin › registerView
Official
Register a custom view.Signature:
registerView(type: string, viewCreator: ViewCreator): voidParameters:
| Parameter | Type | Description |
|---|---|---|
| type | string | The view type. |
| viewCreator | ViewCreator | A function that creates the view for a given leaf. |
Returns: void
Since: 0.9.7
Example:
plugin.registerView('my-view', (leaf) => { return new MyView(leaf);});