SendLit logoSendLit Docs
Email Blocks

EmailPreview

Render a scaled email preview.

EmailPreview renders email HTML into a sandboxed iframe and scales it to the available width.

Usage

This is the exact code behind the demo above (using defaultTemplateEmail here for brevity — the demo renders a fuller sample email).

import { EmailPreview, defaultTemplateEmail } from "@sendlit/email-blocks";

function Example() {
    return <EmailPreview content={defaultTemplateEmail} minHeight="360px" />;
}

On this page