-
Notifications
You must be signed in to change notification settings - Fork 93
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Need a programmatic way to remove a toast #28
Comments
I might be missing something, but
Since you have the returned toast object, whenever you need to remove the toast, use that object's parameters to call clear. var toast = toasterService.pop();
toasterService.clear(toast.toastId, toast.toastContainerId); |
Awesome! That was not documented on the github README, so I did not know :) Thanks! |
You are absolutely right, it is not! My apologies for that oversight. I'll make sure to add an example in the near future. Thank you for pointing it out. |
Added documentation for the clear function in toasterService in response to #28.
toasterService.pop returns a toast object.
I need a way to close / remove that toast at a later time when it is not applicable anymore. There might be multiple toasts displayed, but I need to remove a specific item.
For example, the toast may indicate that someone is requesting that their microphone is opened, but then change their mind. So it is important to remove the toast when it is not valid anymore.
The text was updated successfully, but these errors were encountered: