-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding an option to append a content hash to the end of font files for cache-busting on glyph changes #51
Conversation
and defeats the purpose of caching. This time, a simple MD5 hash is made in order to change the file suffix only when the contents have changed
…ngth > file.minified.length) {` block so we only execute this new logic now if there's a minified file that needs to be output.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
impl looks great! could we get a quick test that ensures the filename is updated in the CSS? :) should be able to reuse the same existing webpack configs for the most part, just utilize appendHash
option
@patrickhulce Did you mean "check that on my end" or did you want a test module written to go along with these changes? |
This one :) |
@patrickhulce I wrote a test to make sure that the hashes appended to the font filenames are referenced in the final assets, that's pushed |
thanks very much @john-positano! a quick patch to fix the lint failures and we're on our way 🎉
|
@patrickhulce I weeded out lint errors. CircleCI can be reran. |
Thanks very much @john-positano! Published in https://github.com/patrickhulce/fontmin-webpack/releases/tag/v3.2.0 |
No description provided.