seek-oss/css-modules-typescript-loader

Empty css.d.ts file

ghostsquad opened this issue · 2 comments

I have a bare bones "create-react-app", and I've added this module. I can see that it's creating the app.css.d.ts file, but it looks like this:

// This file is automatically generated.
// Please do not change this file!
interface CssExports {

}
export const cssExports: CssExports;
export default cssExports;

nvm. The names of my files were wrong. create-react-app requires the names to be <something>.module.css but it comes with app.css out of the box.

In my case it was an error because of wrong loaders sequence. Just put css-modules-typescript-loader right after style-loader and everything goes as expected.