HextaUIHextaUI
/Components/Marketing

Newsletter Signup

A customizable newsletter signup form with validation and success message.

Preview

Subscribe to our newsletter

Stay up to date with our latest news and updates.

This component is available on 21st.dev.

Installation

NPM
npx shadcn@latest add "https://21st.dev/r/hextaui/newsletter-signup"

Usage

import { NewsletterSignup } from "@/components/library/marketing/NewsletterSignup";

const MyComponent = () => {
  const handleSubmit = async (email: string) => {
    // Handle form submission
    await submitToAPI(email);
  };

  return <NewsletterSignup onSubmit={handleSubmit} />;
};

Props

PropTypeDefault
className?
string
-
onSubmit
(email: string) => Promise<void>
-
Edit on GitHub

Last updated on