Skip to main content

Crate leptos_hl_contact

Crate leptos_hl_contact 

Source
Expand description

§leptos-hl-contact

A reusable, secure contact form plugin for Leptos v0.8.

§Architecture

┌──────────────────────────────────────────┐
│  UI Component  (ContactForm)             │  client + server
├──────────────────────────────────────────┤
│  Server Function (submit_contact)        │  server only
├──────────────────────────────────────────┤
│  Delivery Backend (ContactDelivery)      │  server only
└──────────────────────────────────────────┘

§Feature flags

FlagEffect
hydrateEnables Leptos hydration for the client side.
ssrEnables server-side rendering and server fns.
islandsEnables Leptos Islands architecture.
smtp-lettreEnables the SMTP delivery adapter.
axum-helpersEnables Axum-specific integration helpers.

§Quick start

See the examples/axum-basic directory for a complete working example.

§Security

SMTP credentials and the recipient address live only on the server. They are never serialised to WASM or returned to the client. See the security documentation.

Re-exports§

pub use components::ContactForm;
pub use config::ContactFormClasses;
pub use config::ContactFormLabels;
pub use config::ContactFormOptions;
pub use config::ContactServerPolicy;
pub use delivery::ContactDelivery;
pub use delivery::ContactDeliveryContext;
pub use error::ContactDeliveryError;
pub use error::ContactFieldErrors;
pub use error::ContactValidationError;
pub use model::ContactInput;
pub use server::submit_contact;

Modules§

components
config
delivery
error
model
security
server