You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For example, I have some notification mechanism. When clicking on a button, I want to show the notification (some UI).
The notification should be closed after a timeout, for example 8 seconds. But it can also be closed manually by clicking some "X" ui element.
My target is, if someone clicked the button, so I need to show the notification.
And then to trigger a timeout to remove the notification after 8 seconds.
That's my second listeners implementation.
And first listener: If notification is closed, I need to cancel the second one listener.
But it does not work.
IF I close the notification, the second listener won't stop though the fact I coded: listnerApi.dispatch(clearAllListeners());
So where am I wrong?
Also please note that I don't want the second listener to be removed, I only want to cancel active running
So basically, I get DELAYING printed, then BYE but the ALSOFINISHED DELAY. I expect the last no to be printed
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
For example, I have some notification mechanism. When clicking on a button, I want to show the notification (some UI).
The notification should be closed after a timeout, for example 8 seconds. But it can also be closed manually by clicking some "X" ui element.
Implementation:
My target is, if someone clicked the button, so I need to show the notification.
And then to trigger a timeout to remove the notification after 8 seconds.
That's my second listeners implementation.
And first listener: If notification is closed, I need to cancel the second one listener.
But it does not work.
IF I close the notification, the second listener won't stop though the fact I coded:
listnerApi.dispatch(clearAllListeners());
So where am I wrong?
Also please note that I don't want the second listener to be removed, I only want to cancel active running
So basically, I get
DELAYING
printed, thenBYE
but the ALSOFINISHED DELAY
. I expect the last no to be printedBeta Was this translation helpful? Give feedback.
All reactions