MCPcopy Index your code
hub / github.com/sourcebot-dev/sourcebot / isCustomTextElement

Function isCustomTextElement

packages/web/src/features/chat/utils.ts:123–125  ·  view source on GitHub ↗
(element: Descendant)

Source from the content-addressed store, hash-verified

121}
122
123export const isCustomTextElement = (element: Descendant): element is CustomText => {
124 return 'text' in element && typeof element.text === 'string';
125}
126
127export const isParagraphElement = (element: Descendant): element is ParagraphElement => {
128 return 'type' in element && element.type === 'paragraph';

Callers 2

slateContentToStringFunction · 0.85
getAllMentionElementsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected