Svelte Toastify

Under development DO NOT USE

Toast Library for svelte

Setup

Import toast and ToastContainer component

import { toast, ToastContainer } from "svelte-toastify";

Configure

toast.configure({
    position: "top-right"
});

Add toast container in App.svelte

<main>
    <div>Your App </div>
    <ToastContainer />
</main>

Usage

Import toast in you component

import { toast } from "svelte-toastify";

To Fire a toast


toast.success("This is a success message");
    
toast.error("This is an error message");

toast.info("This is an info message");

toast.warn("This is an warning message");

Top categories

svelte logo

Want a Svelte site built?

Hire a Svelte developer
Loading Svelte Themes