Skip to content

Commit 3390bfe

Browse files
authored
Ensure on dismiss callback fires properly (#645)
1 parent a40b6f0 commit 3390bfe

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/index.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,7 @@ const Toast = (props: ToastProps) => {
236236
React.useEffect(() => {
237237
if (toast.delete) {
238238
deleteToast();
239+
toast.onDismiss?.(toast);
239240
}
240241
}, [deleteToast, toast.delete]);
241242

0 commit comments

Comments
 (0)