/
githubmirror
/
novu
Обзор
Документация
Войти
/
githubmirror
/
novu
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
next
libs/maily-render/src/render.ts
13 строк
435 B
Paweł Tymczuk
chore(root): move maily packages to monorepo fixes NV-6941 (#9583)
02 дек 2025, 15:36
Не верифицирован
02 дек 2025, 15:36
0583a9c
Код
Авторство
О чём код?
import type { JSONContent } from '@tiptap/core'; import type { MailyConfig, RenderOptions } from './maily'; import { Maily } from './maily'; export async function render(content: JSONContent, config?: MailyConfig & RenderOptions): Promise<string> { const { theme, preview, ...rest } = config || {}; const maily = new Maily(content); maily.setPreviewText(preview); maily.setTheme(theme || {}); return maily.render(rest); }