DEV Community

Discussion on: How to use modals with forms in Rails using Turbo

 
dstull profile image
Doug Stull • Edited

I don't think it is that bad actually.

However, I think this is the correct solution

see my latest commit on gitlab.com/doug.stull/turbo_modal/...

reasoning:

  • from this line it looks like connect is the only thing that is sure that the stream as finished rendering.

See if that works for you?

Thread Thread
 
matiascarpintini profile image
Matias Carpintini

Awesome, thank you!

Thread Thread
 
dstull profile image
Doug Stull

Thank you, for providing great feedback that helped with the iteration here! I tried this solution with slim select and of course the customary console.log debugging and it seems to work for me, so I merged it and updated the blog post.