UNPKG

@maizzle/framework

Version:

Maizzle is a framework that helps you quickly build HTML emails with Tailwind CSS.

29 lines 1.22 kB
//#region src/utils/output-markers.d.ts /** * Sentinel attributes the `<Plaintext>` and `<NotPlaintext>` * components stamp on their wrapper `<div>` so the build step * can route their slot content to one output and remove it * entirely from the other. */ declare const PLAINTEXT_ONLY_ATTR = "data-maizzle-plaintext-only"; declare const HTML_ONLY_ATTR = "data-maizzle-html-only"; /** * Strip output markers for the HTML output: drop plaintext-only * subtrees entirely, unwrap html-only wrappers (keep children). * * When no markers are present, the input is returned unchanged so * the post-transformer formatting (prettify, XHTML self-closing * slashes, etc.) survives intact for the typical case. */ declare function stripForHtml(html: string): string; /** * Strip output markers for the plaintext source: drop html-only * subtrees entirely, unwrap plaintext-only wrappers (keep children). * * The result is fed to `createPlaintext`, which then strips all * remaining tags via `string-strip-html`. */ declare function stripForPlaintext(html: string): string; //#endregion export { HTML_ONLY_ATTR, PLAINTEXT_ONLY_ATTR, stripForHtml, stripForPlaintext }; //# sourceMappingURL=output-markers.d.ts.map