You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Template fragments are a relatively rare Server Side Rendering (SSR) template library feature that allow you to render a fragment or partial bit of the content within a template, rather than the entire template. This feature is very handy in Hypermedia Driven Applications because it allows you to decompose a particular view for partial updates internally without pulling fragments of the template out to separate files for rendering, creating a large number of individual template files.
By keeping all the HTML in a single file, it is also easier to reason about how a feature works. This follows the Locality of Behavior design principle.
There is a list of those template engines that do have fragments support at the bottom of the page.
I am a big advocate of LOB in web design and feel that my raku HTMX examples would be cleaner and more maintainable (as would any HTMX site using Cro) if Cro had Fragments.
The text was updated successfully, but these errors were encountered:
According to the author of HTMX (Carson Gross)
https://htmx.org/essays/template-fragments/
Here is the example he presents:
There is a list of those template engines that do have fragments support at the bottom of the page.
I am a big advocate of LOB in web design and feel that my raku HTMX examples would be cleaner and more maintainable (as would any HTMX site using Cro) if Cro had Fragments.
The text was updated successfully, but these errors were encountered: