Pure, beautiful Ruby
Phlex gives you HTML semantics in Ruby so you can use your existing skills designing object-oriented views. Plus, you get to use tools like RubyLSP, Rubocop and Simplecov.
Phlex gives you HTML semantics in Ruby so you can use your existing skills designing object-oriented views. Plus, you get to use tools like RubyLSP, Rubocop and Simplecov.
Phlex renders HTML at ~1gbps per core on a MacBook Pro (M3 Max) and it doesn’t slow down the more components you extract.
Phlex works great with Rails. It supports all Rails helpers and plays nicely with ViewComponent, ActionView, Stimulus, Turbo and Tailwind.
Phlex is designed to structurally prevent cross-site-scripting (XSS) attacks by default.
Phlex components only depend on the data you pass in, making them easier to test and reuse.
Phlex has no dependencies and the Rails extension only depends on Rails itself.
You can package up components into “kits” for easy reuse across projects. Kits can be shared with the community as Ruby gems or kept for internal use.
You can render a view targeting a specific DOM ID. Phlex only does the work to render just the parts you want. This is great for partial Hotwire updates like Turbo Frames.
Phlex can stream responses to boost time to first byte (TTFB). In some cases users can see the first static content before the database has even responded.