Doesn't export fields with css-loader ^4.0.0
See original GitHub issueWe are using css-modules-typescript-loader to generate our types with CSS modules, css-loader and sass.
I’m seeing an issue in the generated typescript files from css-modules-typescript-loader
. When we update to css-loader
version 4, the exports have no fields in CssExports.
This works fine with css-loader
version 3.6.0 but issue appears when updating to css-loader
version 4.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:14
- Comments:7 (1 by maintainers)
Top Results From Across the Web
Webpack style-loader and css-loader not working on a ...
I am having an issue on a simple project, after configuring webpack.config.js const HTMLPlugin = require('html-webpack-plugin') const ...
Read more >postcss-loader | webpack - JS.ORG
In the following configuration the plugin postcss-preset-env is used, which is not installed by default. file.js import css from "file.css";. webpack.config ...
Read more >postcss-loader
npm install --save-dev postcss-loader postcss ... module.exports = { ... We recommend do not specify from , to and map options, because this ......
Read more >Migrating from v2 to v3
fs, node.path, ...) process is not defined. GraphQL: character escape sequences in regex filter; GraphQL: __typename field is no ...
Read more >How to use Webpack with React: an in-depth tutorial
This is where Babel looks at that file. Second Rule. We test for CSS files with a .css extension. Here we use two...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
For css-loader version 4 has different local export name from version 3. In the index.js file line 83, we can add function to make it work for both versions. See the pull request below for the fix.
FYI: I ended up switching to
@teamsupercell/typings-for-css-modules-loader
as this repo seems no longer maintained. Worked with that loader.