gajus / babel-plugin-react-css-modules

Transforms styleName to className using compile time CSS module resolution.
Other
2.05k stars 162 forks source link

Redundant mapping object in production output #278

Closed pot-code closed 3 years ago

pot-code commented 4 years ago

Happened to get two class name mapping objects in production code

first: image

second: image

react code: image

The component has already used the mapped className, there is no need to emit the mapping object in final build if I understand it correctly.

gajus commented 4 years ago

A patch is welcome.

pot-code commented 3 years ago

haven't used it for a while, just close it