Skip to content
Viewership Inquire
Astro UI

Newsletter.

Email sign-up with a short pitch and privacy line. A plain HTML form you point at any provider.

ConversionSectionNo dependencies Original, MIT

.md

Field notes, monthly.

Trip reports, repair tips and first look at new batches. One email a month.

No spam. Unsubscribe in one click.

Style

Using Claude Code? Give it the agent prompt and skip these steps.

  1. Import the foundation once

    foundation.css holds the tokens every component reads.

    Layout.astro
    ---
    // src/layouts/Layout.astro
    import "../styles/foundation.css";
    ---
  2. Copy Newsletter.astro

    Paste into src/components/viewership/newsletter/

  3. Use it

    Page.astro
    ---
    import Newsletter from "../components/viewership/newsletter/Newsletter.astro";
    ---
    
    <Newsletter />

Props 10

PropTypeDefaultDescription
title string · Headline.
accent string · Closing words of the headline.
body string · Short pitch.
action string · Form endpoint (your email provider or a serverless function).
method "post" | "get" "post" Form method.
field string "email" Name of the email field.
placeholder string "you@example.com" Input placeholder.
button string "Subscribe" Button label.
note string · Small print under the form.
as "h2" | "h3" "h2" Heading element.

Source 1 file

Original, MIT.