From bb74a0517971d4832cf2fcac53429c5b7f2648ea Mon Sep 17 00:00:00 2001 From: Nadar Date: Fri, 24 Nov 2023 09:44:02 +0000 Subject: [PATCH] add hardbreak --- src/wysiwyg.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/wysiwyg.ts b/src/wysiwyg.ts index e5353a7..1b3d504 100644 --- a/src/wysiwyg.ts +++ b/src/wysiwyg.ts @@ -10,6 +10,7 @@ function wysiwyg(json: any, nodeRenderers: any) { bulletList: ({ content }: { content: any[] }, renderNode: any) => ``, orderedList: ({ content }: { content: any[] }, renderNode: any) => `
    ${content.map(child => `
  1. ${renderNode(child)}
  2. `).join('')}
`, listItem: ({ content }: { content: any[] }, renderNode: any) => `${content.map(child => renderNode(child)).join('')}`, + hardBreak: () => `
`, blockquote: ({ content }: { content: any[] }, renderNode: any) => `
${content.map(child => renderNode(child)).join('')}
`, image: ({ attrs }: { attrs: { src: string, alt: string, title: string } }) => `${attrs.alt}`, youtube: ({ attrs }: { attrs: { src: string, start: string } }) => ``,