Skip to content
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

fix(gatsby): Use hex hash for CSS modules #36701

Merged
merged 1 commit into from
Sep 27, 2022
Merged

Conversation

tyhopp
Copy link
Contributor

@tyhopp tyhopp commented Sep 27, 2022

Description

We use a base64 hash for CSS modules, and the (non-variant) base64 lexicon contains the the plus character (+), which is the adjacent-sibling combinator (.a + .b) in CSS.

Switch to hex instead. Tried base64url (introduced in Node 14.18.0) but it doesn't work (maybe webpack docs are incorrect, will look into this).

Paper trail:

Documentation

N/A

Related Issues

Fixes #36673

@gatsbot gatsbot bot added the status: triage needed Issue or pull request that need to be triaged and assigned to a reviewer label Sep 27, 2022
@tyhopp tyhopp added topic: webpack/babel Webpack or babel topic: core Relates to Gatsby's core (e.g. page loading, reporter, state machine) and removed status: triage needed Issue or pull request that need to be triaged and assigned to a reviewer labels Sep 27, 2022
@pieh pieh merged commit 0683ae8 into master Sep 27, 2022
@pieh pieh deleted the fix/gatsby-css-module-hash branch September 27, 2022 07:48
@LekoArts LekoArts added this to To cherry-pick in V4 Release hotfixes via automation Oct 6, 2022
LekoArts pushed a commit that referenced this pull request Oct 6, 2022
@LekoArts LekoArts moved this from To cherry-pick to Backport PR opened in V4 Release hotfixes Oct 6, 2022
LekoArts pushed a commit that referenced this pull request Oct 7, 2022
Co-authored-by: Ty Hopp <tyhopp@users.noreply.github.com>
@LekoArts LekoArts moved this from Backport PR opened to Published in V4 Release hotfixes Oct 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: core Relates to Gatsby's core (e.g. page loading, reporter, state machine) topic: webpack/babel Webpack or babel
Projects
Development

Successfully merging this pull request may close these issues.

CSS Modules build output hash not escaped
2 participants