Hacker News new | ask | show | jobs
by ignurant 1087 days ago
I usually conditionally include the visibility toggle class from the erb side, so the first time it renders as html it has the toggle correctly initiated. I can see situations where the visibility logic is hard or impossible from the Ruby side, but I haven’t had this issue yet.
1 comments

Unfortunately I haven't come up with a good solution either beyond hiding the element with CSS, and then showing it when the controller connects (which isn't ideal). I'd love any suggestions though for different techniques