shakee93 / vue-toasted

🖖 Responsive Touch Compatible Toast plugin for VueJS 2+
https://shakee93.github.io/vue-toasted/
MIT License
2.21k stars 194 forks source link

Only one toast at a time #37

Closed sergiocastrovale closed 7 years ago

sergiocastrovale commented 7 years ago

Is there a way to globally prevent that no more than a single toast is shown simultaneously? I'm trying to prevent this from happening:

screenshot_1

I know I could just use the recently-added clear method but it seems a bit too overwhelming to have to make that call each time I trigger a toast. I was wondering if I could clear all toasts as soon as a new one is shown.

shakee93 commented 7 years ago

it will be available in the upcoming build. singleton : true or something..

sergiocastrovale commented 7 years ago

That's awesome. Maybe unique: true?

Any idea on when it will be available? Thanks for the great package and fast support.

shakee93 commented 7 years ago

i think singleton gives the idea of the options than unique. maybe in couple of hours 🚀 cheers !!

lsc949982212 commented 5 years ago

the bug is exist still on version 1.1.24, how to resolve?

ZtheLeader commented 5 years ago

singleton: true is not working as action.

mpalencia commented 5 years ago

singleton: true --> still not working on 1.1.27 any idea on how to implement this?

FilArt commented 5 years ago

singleton: true --> still not working on 1.1.27 any idea on how to implement this?

you can use this.$toasted.clear() to kill old notys