Skip to content
Het fundament eronderUI and contentemail

Mail die de app verstuurt

Uitnodigingen, meldingen, exportlinks, rapportleveringen.

Growth-OS stuurt mail voor een kleine set dingen: een collega uitnodigen, een melding waar iemand zich op abonneerde, een link naar een data-export, een dashboardrapport, een verlofnotitie. Sjablonen zijn getypeerde componenten in de repository met één gedeelde responsieve opmaak, dus er een aanpassen is een gewone codewijziging met review en historie.

  • 1 path every email goes through
  • 5 shared templates in the repository
  • 0 email secrets in browser code

Hoe het werkt

Het mechanisme van begin tot eind, zoals het in de repository is geïmplementeerd.

  1. 1

    Pick or write a template

    Typed components take props for names, amounts and links. Five shared templates use one responsive layout, and the local preview shows desktop, mobile, text and source.

  2. 2

    Send from the server

    A server service or background job calls one helper with the component, a recipient and a subject. The helper reads server-only configuration, so it cannot end up in browser code.

  3. 3

    It renders and delivers

    The helper renders the component to HTML with a plain-text alternative and hands it to the provider. A provider error is rethrown so the calling job owns the retry.

  4. 4

    Unconfigured is a skip, not a lie

    Without a key or a from-address the helper logs a development warning and returns without claiming a delivery happened.

Interactief voorbeeld

Bekijk het in werking

Deze rondleiding toont het geïmplementeerde backendcontract zonder account, credentials of providercalls.

Interactief voorbeeld

Explore the decisions this makes

Kies een voorbeeldstatus
Welcome component

Alleen deterministische voorbeelddata. De interactie gebruikt geen account-, provider- of netwerkverbinding.

Het probleem dat dit oplost

Zonder een gedeelde basis bouwt elk team deze randgevallen opnieuw, en anders.

The template that broke quietly

Mail that lives in a vendor dashboard has no link to the code. A field gets renamed, and weeks later someone receives a message with a placeholder in it. Typed templates fail the build instead.

Five features, five ways to send

Each feature spinning up its own client means from-addresses drift, errors are swallowed differently, and changing provider becomes a hunt. One helper is one place to change.

Blocked on day one without a key

An app that crashes at boot without an email key forces everyone to either hold production credentials or wrap every send in a condition. Here a missing key turns a send into a logged skip.

Kernpunten

Waarom dit belangrijk is

Templates are code

Five shared templates live in the repository as typed components with matching MJML variants. Renaming a field they use fails the build instead of sending a broken line to someone.

One door for every send

Every feature and background job sends through the same helper, so the from-address, rendering and error handling live in one place.

No keys, no crash

Without an email key a send logs a warning and returns. Local work and tests run without production credentials, and nothing pretends a message was delivered.

Technische garanties

Wat dit wel en niet belooft

Veiligheidsgrens

Deze pagina toont hoe een sjabloon eruitziet; ze verstuurt nooit iets. Of een bericht een inbox bereikt, hangt af van de domeininstellingen en de provider, en dat valt buiten deze code. Campagnes in de werkruimte zijn iets anders en versturen nog steeds helemaal niets.

Implementatiebewijs

De grens hierboven is geen claim maar code. Deze bestanden dragen het contract:

  • src/lib/email.ts
  • src/lib/email/templates
  • src/features/privacy/jobs.ts
Vragen

Veelgestelde vragen

Waar Mail die de app verstuurt op rust

De documentatie beschrijft dezelfde contracten die deze pagina demonstreert.