Skip to content

[hot]fix broken css module support in prod - #4361

Merged
andriijas merged 1 commit into
react:nextfrom
andriijas:css-module-fix
Apr 27, 2018
Merged

[hot]fix broken css module support in prod#4361
andriijas merged 1 commit into
react:nextfrom
andriijas:css-module-fix

Conversation

@andriijas

Copy link
Copy Markdown
Contributor

hot fix missmatch between .dev and .prod making css modules not matched correctly when building for production.

long term fix will be to break out common config to seperate file to avoid missmatch.

@andriijasandriijas added this to the 2.0.0 milestone Apr 25, 2018
@iansu

Copy link
Copy Markdown
Contributor

Are these CI failures related to these changes? It seems to be failing on building the production bundle.

@andriijas

Copy link
Copy Markdown
ContributorAuthor

@iansu not sure, i just noticed the missmatch in the files and backtracked before scss was added.

@Fabianopb can you verify this?

@iansuiansu mentioned this pull request Apr 25, 2018
@Fabianopb

Copy link
Copy Markdown
Contributor

@andriijas I took a look (good catch btw) and it seems to be working fine, I've just tried that in my local instance with the hotfix and the production build is working just fine, css module names are matching.

I'm not sure if this is related to css/sass modules as kitchensink tests passed with node 8 and 9... I've experienced this error ("An error was encountered executing line XYZ") when trying to run e2e tests locally, but it seems they are not working. Could it be that the CI has some bug in the test suite? Is it possible to manually re-run the tests in the CI just in case?

@andriijas

Copy link
Copy Markdown
ContributorAuthor

I think the the CI is showing false negative. This is the previous version before sass support: https://github.com/facebook/create-react-app/blob/ae2cf072494c332f3252d5109d4e2ef505749048/packages/react-scripts/config/webpack.config.prod.js#L292

@andriijas
andriijas merged commit cc36849 into react:nextApr 27, 2018
@andriijas
andriijas deleted the css-module-fix branch April 27, 2018 06:04
kellyrmilligan added a commit to kellyrmilligan/create-react-app that referenced this pull request May 2, 2018
* upstream/next: (35 commits)
Update envinfo and issue template (react#4375)
Update sass-loader to 7.0.1 (react#4376)
Support package distribution tags (react#4350)
fix broken css module support in prod (react#4361)
Bumped jest version to 22.4.1 (react#4362)
bump babel 7 to beta 46
bump lint-staged to node 10 compatible version
documentation: Added License to the README.md (react#4294)
Bump `fsevents`. (react#4331)
Fix typo in e2e-simple.sh comment (react#4323)
Add Sass loader (react#4195)
Fix some typos in README.md (react#4286)
Added learnstorybook.com to Storybook links (react#4298)
Document multiple build environments via `env-cmd` react#4071 (react#4117)
Fixed link to CSS imports blog post
Update CSS Modules localIndetName (react#4192)
Enable loose mode for `class-properties` (react#4248)
bump babel 7 beta (react#4253)
Small typo fixreact#4217
Changelog for 1.1.4
...
kellyrmilligan added a commit to kellyrmilligan/create-react-app that referenced this pull request May 2, 2018
* next: (35 commits)
Update envinfo and issue template (react#4375)
Update sass-loader to 7.0.1 (react#4376)
Support package distribution tags (react#4350)
fix broken css module support in prod (react#4361)
Bumped jest version to 22.4.1 (react#4362)
bump babel 7 to beta 46
bump lint-staged to node 10 compatible version
documentation: Added License to the README.md (react#4294)
Bump `fsevents`. (react#4331)
Fix typo in e2e-simple.sh comment (react#4323)
Add Sass loader (react#4195)
Fix some typos in README.md (react#4286)
Added learnstorybook.com to Storybook links (react#4298)
Document multiple build environments via `env-cmd` react#4071 (react#4117)
Fixed link to CSS imports blog post
Update CSS Modules localIndetName (react#4192)
Enable loose mode for `class-properties` (react#4248)
bump babel 7 beta (react#4253)
Small typo fixreact#4217
Changelog for 1.1.4
...
zmitry pushed a commit to zmitry/create-react-app that referenced this pull request Sep 30, 2018
@locklockBot locked and limited conversation to collaborators Jan 20, 2019
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@andriijas@iansu@Fabianopb@facebook-github-bot