3 ms·
The ViewComponent (viewcomponent.org) project brings a lot of the benefits of components to Rails views. It makes data dependencies explicit, it makes them test
by multiplegeorges 3y ago
The ViewComponent (viewcomponent.org) project brings a lot of the benefits of components to Rails views. It makes data dependencies explicit, it makes them testable, and reusable.
Worth checking out, but it doesn't address unidirectional data flow and hooks, since those are not relevant in a Rails context.
Personally, having state on the server and updating html over the wire is far superior to managing client-side state.