Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • C create-react-app
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,547
    • Issues 1,547
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 417
    • Merge requests 417
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Meta
  • create-react-app
  • Issues
  • #7561
Closed
Open
Issue created Aug 18, 2019 by Administrator@rootContributor

Hot reload is not working with CSS modules, starting in 3.1.0

Created by: igorstajic

Describe the bug

Hot reload is not working with CSS modules, after upgrading react-scripts to 3.1.0 or 3.1.1 It works fine with react-scripts 3.0.1

Which terms did you search for in User Guide?

CSS modules hot reload

Environment

System: OS: macOS 10.14.6 CPU: (12) x64 Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz Binaries: Node: 10.16.2 - ~/.nvm/versions/node/v10.16.2/bin/node Yarn: 1.16.0 - /usr/local/bin/yarn npm: 6.10.3 - ~/.nvm/versions/node/v10.16.2/bin/npm Browsers: Chrome: 76.0.3809.100 Firefox: 67.0.4 Safari: 12.1.2 npmPackages: react: ^16.9.0 => 16.9.0 react-dom: ^16.9.0 => 16.9.0 react-scripts: 3.1.1 => 3.1.1 npmGlobalPackages: create-react-app: Not Found

Steps to reproduce

  1. Create a new app with "npx create-react-app"
  2. Add Test.module.css file and import in in App.js
  3. Try editing the css module file, it will reload the whole app.

Expected behavior

Editing the css module should be hot reloaded.

Actual behavior

The whole app is reloaded when the css file is edited.

Reproducible demo

https://github.com/igorstajic/cra-css-module-issue

Assignee
Assign to
Time tracking