Suggestions for the namespace
and css
twig tags to make templating more component oriented.
#9939
-
Suggestions for the
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Agree we should probably apply
This wouldn’t work on load-balanced servers as the file would only be generated on the server that served the initial page request. |
Beta Was this translation helpful? Give feedback.
{% namespace %}
is generally used to namespace IDs and form input names. Prefixing class names by default would be a massive breaking change that would require most instances adding awithoutClasses
, so not going to happen. Even if it were just configurable but disabled by default, that would still have other consequences, such as for plugins that provide example front-end template code.Agree we should probably apply
withClasses
to nested{% css %}
tags. That would also be a breaking change (albeit less risky), so I’ll look into it for Craft 4.This wouldn’t work on loa…