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
Basically as the title says: after a Turbo form submission, if I redirect to the same page then the Stimulus lifecycle events don't fire. Any new Stimulus controllers that are in the redirected-to page don't have their connect methods called, and hence they don't initialize.
Is it a bug, or expected behaviour? And is there a workaround?
The text was updated successfully, but these errors were encountered:
Morphing is indeed enabled, and it does seem related to that thread.
The solutions in that thread didn't work for me, although I was able to get around the issue by adding a "dummy" param (for example success=true) to the path I redirect to to force the disconnect/reconnect. It's a bit ugly, but at least works for now.
Still, this was pretty surprising behaviour, so it would be nice to have a better, "sanctioned" solution to this.
Hello,
Basically as the title says: after a Turbo form submission, if I redirect to the same page then the Stimulus lifecycle events don't fire. Any new Stimulus controllers that are in the redirected-to page don't have their
connect
methods called, and hence they don't initialize.Is it a bug, or expected behaviour? And is there a workaround?
The text was updated successfully, but these errors were encountered: