fkhadra / react-toastify

React notification made easy 🚀 !
https://fkhadra.github.io/react-toastify/introduction
MIT License
12.27k stars 673 forks source link

Inconsistent Notification Stacking with stacked and newestOnTop #1094

Open in0vik opened 2 months ago

in0vik commented 2 months ago

When using React-Toastify with both stacked and newestOnTop options enabled, the notification stack behaves inconsistently, with notifications appearing to jump or reorder unpredictably.

aminBenSlimen commented 1 month ago

It shouldn't act this way but i think you don't need newestOnTop since there will be only one visible with stacked set to true unless you're dynamically changing stacked, in that case that's your situation a simple workaround for this bug is to make sure when an option is true the other is not. <ToastContainer stacked={useStacked} newestOnTop={!useStacked} />