useEditorSelector
useEditorSelector<
TSelected
>(editor
,selector
,compare
):TSelected
Defined in: packages/editor/src/editor/editor-selector.ts:42
Hook to select a value from the editor state.
Type Parameters
• TSelected
Parameters
editor
selector
EditorSelector
<TSelected
>
compare
(a
, b
) => boolean
Returns
TSelected
Examples
Pass a selector as the second argument
Pass an inline selector as the second argument. In this case, use the editor context to obtain the schema.