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
While testing the new defer feature, I found a peculiar issue in (at least) Chrome and Safari.
This is the typical "TailwindCSS workflow." I have previously recommended a workflow that watches the hugo_stats.json for changes, and in that setup, this isn't an issue (you get 2 builds, first the HTML, then the CSS).
But if you build both in one Go, we do a full browser reload, and the HTML change is visible, but not the CSS change (no fingerprinting of the CSS file).
This situation can be detected, and I have tested that this works:
First do a reload of the page.
Wait some ...
Do a refresh of (only) the changed CSS.
The text was updated successfully, but these errors were encountered:
This seems to be a browser bug (tested in both Chrome and Safari on MacOS), but it seems that doing a `window.location.reload()` (or `window.location.reload(true)`) doesn't refresh the CSS changes, even if HTTP caching is disabled.
This commit works around this by doing additional refreshes of the CSSes.
Closesgohugoio#12600
While testing the new
defer
feature, I found a peculiar issue in (at least) Chrome and Safari.This is the typical "TailwindCSS workflow." I have previously recommended a workflow that watches the
hugo_stats.json
for changes, and in that setup, this isn't an issue (you get 2 builds, first the HTML, then the CSS).But if you build both in one Go, we do a full browser reload, and the HTML change is visible, but not the CSS change (no fingerprinting of the CSS file).
This situation can be detected, and I have tested that this works:
The text was updated successfully, but these errors were encountered: