Open janpaepke opened 3 months ago
Currently facing the same problem.
In my case when toaster.update
is at same level of ToasterContainer
I have this problem. If i move toaster.update
to some downstream children it starts working as expected.
I can see that containerIds are well generated without having any conflict, just the rendering is not working as expected.
Do you want to request a feature or report a bug? I'm pretty sure this is an unintentional bug.
What is the current behavior? When specifying a containerId when caling toast(), an update to the resulting toastID will fail silently (it just does nothing).
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem. Your bug will get fixed much faster if we can run your code and it doesn't have dependencies other than React. Paste the link to your CodeSandbox (https://codesandbox.io/s/new) example below:
The code below fails, which at least to me is unexpected as toastIDs are globally unique, not per container.
See here for the codesandbox example.
What is the expected behavior? I would expect the update to work without passing the containerId.
Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React? independent of React.