css-modules-typescript-loader icon indicating copy to clipboard operation
css-modules-typescript-loader copied to clipboard

style-loader docs is missing

Open quebits opened this issue 6 years ago • 0 comments

As I can see behaviour of the loader is tightly coupled with style-loader webpack's plugin.

For example:

index.css

.selector { /* */ }

index.css.d.ts

// This file is automatically generated.
// Please do not change this file!
interface CssExports {
  'selector': string
}
export const cssExports: CssExports;
export default cssExports;

index.js

import styles from './index.css'

console.log(styles['selector'])

Such access is only available with style-loader enabled. But there is no reference nor in documentation itself nor in example.

quebits avatar Feb 11 '20 14:02 quebits