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

Automatic CSS Modules #549

Open
insin opened this issue May 3, 2020 · 1 comment
Open

Automatic CSS Modules #549

insin opened this issue May 3, 2020 · 1 comment

Comments

@insin
Copy link
Owner

insin commented May 3, 2020

css-loader now has config for automatically enabling CSS modules for .module.{ext} files:

 createLoader(name('css'), {
   loader: require.resolve('css-loader'),
   options: {
     // Apply postcss-loader to @imports
     importLoaders: 1,
   },
+  // Automatically enable css modules for .module.{ext} files
+  modules: {auto: true},
 }),

Should we turn this on?

@HongJheLi
Copy link

Sure, please add it by default.

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

No branches or pull requests

2 participants