Skip to main content
Modular Documentation
Guides
Reference
Reference
/
@modular/sdk/editor
$isTextPointCaretSlice
function
Guard to check for a TextPointCaretSlice
function $isTextPointCaretSlice<D extends CaretDirection>(caretOrSlice: null | undefined | PointCaret<D> | TextPointCaretSlice<TextNode, D>): caretOrSlice is TextPointCaretSlice<TextNode, D>
Import
import { $isTextPointCaretSlice } from '@modular/sdk/editor';
Notes
returns
true if caretOrSlice is a TextPointCaretSlice