Elffuss BraidHub

kikocis/continue public

7aa6d9f92b99 · 321 BRawPermalink
1import { JSONContent } from "@tiptap/core";
2
3export function getParagraphNodeFromString(str: string): JSONContent {
4 return {
5 type: "doc",
6 content: [
7 {
8 type: "paragraph",
9 content: [
10 {
11 type: "text",
12 text: str,
13 },
14 ],
15 },
16 ],
17 };
18}