Defect #29625
closedapplication.css imported by themes not covered by cache control versioning
0%
Description
The subject and #24617-12 pretty much says it all.
After an update, the old application.css still gets used by browsers' caches, with no means other than renaming the file and its import statements in the used theme to force cache invalidation.
Partial workaround:
public/themes/<activetheme>/stylesheets/application.css
Change import statement
@import url(../../../stylesheets/application.css);
to some other name (e.g. application_v2.css)
Rename public/stylesheets/application.css to e.g. application_v2.css
Also apply the cache control hack in the mentioned ticket.
However, you can still never go back to application.css as browsers will still keep it cached forever. A fix is needed that makes the filename unique on every update, much like all other resources.
This may also affect other resources delivered by themes (e.g. images), so a best practice should be given for how to avoid that as well.
Related issues