Skip to content

[2.0.5] CSS Modules hash mismatch (React SSR) #222

Closed

Description

@chrisblossom

I have a React SSR that uses Webpack on the client and server. After updating to postcss-loader v2.0.3, my generated CSS Module hash's are different on the client and the server.

I am unsure if the issue is related to postcss-loader directly or if it is a new/updated dependency brought in by v2.0.3.

I can bring up a skeleton repository if that would help to demonstrate the issue I am having.

Activity

  1. michael-ciniawsky commented on May 9, 2017

    @michael-ciniawsky
    Contributor

    @chrisblossom Yep please provide a small repo, are you using sourcemaps in postcss-loader ?
    Note that we are in the transition phase to move CSS Modules from css-loader into postcss-loader via a compatible PostCSS Plugin in the future

  2. changed the title [-]Universal css modules mismatch[/-] [+][2.0.3] CSS Modules hash mismatch (React SSR)[/+] on May 9, 2017
  3. changed the title [-][2.0.3] CSS Modules hash mismatch (React SSR)[/-] [+][2.0.5] CSS Modules hash mismatch (React SSR)[/+] on May 11, 2017
  4. chrisblossom commented on May 17, 2017

    @chrisblossom
    Author

    During the process of gutting my app to give an example repository, I found the following in my server webpack config:

            new webpack.LoaderOptionsPlugin({
                options: {
                    context: __dirname,
                },
            }),

    After removing that, everything works as expected. Thanks for the quick reply!

  5. theasia-Ashish commented on May 22, 2017

    @theasia-Ashish

    @chrisblossom your comment save my life, after struggling this checksum warning nearly a month.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Type

No type

Fields

Priority

None yet

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions