Skip to content
This repository has been archived by the owner on Jan 11, 2023. It is now read-only.

No hash appended to client.css filename in v0.29.0 #1716

Closed
fivemru opened this issue Feb 2, 2021 · 0 comments · Fixed by #1717
Closed

No hash appended to client.css filename in v0.29.0 #1716

fivemru opened this issue Feb 2, 2021 · 0 comments · Fixed by #1717

Comments

@fivemru
Copy link
Contributor

fivemru commented Feb 2, 2021

Describe the bug
Sapper version 0.29.0 does not add a hash to the client.css file. For other css files the hash is added.

To Reproduce

npx degit "sveltejs/sapper-template#rollup" my-app-0.29.0 \
&& cd my-app-0.29.0 \
&& npm i \
&& npm i -D sapper@0.29.0 \
&& npm run build \
&& ls -la __sapper__/build/client/*.css

output:

__sapper__/build/client/[slug]-5bc8f95f.css
__sapper__/build/client/client.css
__sapper__/build/client/index-39716d32.css
__sapper__/build/client/index-7ed37c94.css

In version 0.28.10 everything is ok.

Expected behavior
File name client.css with hash like this:

__sapper__/build/client/client-abcdefg.css

Severity
Due to caching of static files, when a new version of the site is released, the user interface is not displayed correctly, users cannot interact with some elements of the site.

Additional context
The problem is related to updating rollup-plugin-css-chunks from 1.2.6 to 2.0.2 in sapper 0.29.0 (#1666).
Since version 2.0.0 rollup-plugin-css-chunks has a default value of entryFileNames: '[name].css', before that it was entryFileNames: '[name]-[hash].css'

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant