phlex
                                
                                
                                
                                    phlex copied to clipboard
                            
                            
                            
                        A framework for building object-oriented views in Ruby.
### Discussed in https://github.com/orgs/phlex-ruby/discussions/583 Originally posted by **bradgessler** July 21, 2023 Sometimes a component needs to be rendered, but the output is not needed, like in this controller at https://github.com/rubymonolith/classic/blob/47d9fee6e17f5f49d7dfbefee4b194b6eddcff8d/app/controllers/posts_controller.rb#L71-L73...
In order to support fast selective rendering, we need to be able to pull the id from the attributes hash quickly, so we need to be able to depend on...
It was brought up in the Discord that we should have a safe way to create dynamic elements. So instead of doing: ```rb send(tag_name, **attributes) ``` which could potentially call...
Otherwise, if one fragment is embedded in another fragment, it will not be able to throw early.
I wanted to open this draft PR so we had a space to talk about the API here. * Internally I've called this data `user_context` * The public API to...
`view_context` is a Rails concern and is now being handled in the phlex-rails gem. Closes #628
Phlex could issue a warning or raise whenever an _element_ method is overridden in a subclass. The warning could be ignored explicitly with a macro, e.g. ```ruby override def title...
Hi everyone, I have a question (more like an advice) about phlex tag registration improvement. We are doing a migration from another rendering gem ([fortitude](https://github.com/ageweke/fortitude)) to phlex and have a...
After reading through #746 I had an idea about how to further optimise nested tokens (Arrays and Sets). 1. `.compact.join` was doing two iterations over the array: one to remove...