If, for one reason or another, you need to extract CSS as a plain string resource (i.e. not wrapped in a JS module) you might want to check out the extract-loader. It's useful when you, for instance, ...
The syntax :local(.className) can be used to declare className in the local scope. The local identifiers are exported by the module. This enables Local scoped CSS by default. (You can switch it off ...