Hacker News new | ask | show | jobs
by Draiken 922 days ago
What do you mean by UI elements defined as ruby components? Are you referring to ViewComponents or something else?
1 comments

Yeah you can define viewcomponents in ruby. Have them rendered based on stimulus code. Turbo lets you do updates without full page reloads, viewcomponents make much more reusable and flexible ruby based components than pure erb, and stimulus handles front end state. I rewrote a medium size react + graphql page with this and thr code base was literally 1/10th the size