Skip to content
This repository was archived by the owner on Oct 30, 2020. It is now read-only.

Commit de2a8fa

Browse files
committed
Add section about exports.local to README
1 parent 81ff68c commit de2a8fa

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,8 @@ export const foo: string;
5555
export const barBaz: string;
5656
```
5757

58+
`css-loader` exports mappings to `exports.locals` which is incompatible with the `namedExport`-option unless paired with `extract-text-webpack-plugin` or `style-loader`. They move the exported properties from `exports.locals` to `exports` making them reuired for `namedExport` to work, and `namedExport` required for them to work. *Always combine usage of `extract-text-webpack-plugin` or `style-loader` with the `namedExport`-option.*
59+
5860
## Usage
5961

6062
Keep your `webpack.config` as is just instead of using `css-loader` use `typings-for-css-modules-loader`

0 commit comments

Comments
 (0)