kbrgl / svelte-french-toast

🍞🥂 Buttery smooth toast notifications for Svelte
https://svelte-french-toast.vercel.app/
MIT License
809 stars 28 forks source link

Are there any alternatives to dismiss notification for custom toasts? #26

Open ksenia-fe opened 1 year ago

ksenia-fe commented 1 year ago

Hi! I have a question about dismissing the notification. You have an example of 'Rich content' toast: <span> Custom and <b>bold</b> <button on:click={() => toast_.dismiss(toast.id)}>Dismiss</button> </span> and advice to use toast such this: toast(RichContent). But can I use RichContent component with my custom message property like this: toast()? Or are there any alternatives to have dismiss button (e.g. dismiss property in options object: true with default Icon like toast.error(message, { style: ..., position: ...., **dismiss: true,** }); ) Thank you in advance