If, when creating the toast, hideAfter is set to false and a subsequent call to update specifies a non-false value for hideAfter, the toast will not automatically close after the specified amount.
For example:
var toast = $.toast({
text: 'doing something',
position: 'top-center',
allowToastClose: false,
hideAfter: false
});
// do someothing that takes some time
toast.update({
text: 'done',
hideAfter: 2000
});
My use case is for saving data. I initially show a "Saving..." message when the save starts, and then I update the message "Save successful" when it completes. The original message should stay up until the latter changes it, however the latter should disappear after a bit.
If, when creating the toast, hideAfter is set to false and a subsequent call to update specifies a non-false value for hideAfter, the toast will not automatically close after the specified amount.
For example:
My use case is for saving data. I initially show a "Saving..." message when the save starts, and then I update the message "Save successful" when it completes. The original message should stay up until the latter changes it, however the latter should disappear after a bit.