.finally(React)

English
Copyright © 2023-currentdotfinally, LLC

Notification

Hey, Listen!

The Notification component can be used by importing { Notification } from "finallyreact".

Note: for each Notification used, you'll need to create a reference object in React, like so: const ref1 = useRef() and use it when triggering the Notification.

Example - 3 seconds

Example - 3 seconds

Styled - 3 seconds

Styled - 3 seconds

Custom Content - 5 seconds

Custom Content - 5 seconds

No Time Limit

No Time Limit

Dynamic notification text

Dynamic notification text

Simple

Simple

Notification Props

Prop NameProp TypeDescription
closePropsHTMLAttributesProps for the close button
onClose() => voidCallback for closing the notification
permanentbooleanWhether the notification is permanent; requires manual closing
simplebooleanSimple notification with no styles
textstringText content for the notification
textPropsHTMLAttributesProps for the text content
timenumberTime in milliseconds to show the notification; default is 3000