3 ms·
With sourcemaps you can get close, but it still shows the "mangled" class name in the HTML. But with a dev/prod environment, you can have your cake and eat it
by Klathmon 10y ago
With sourcemaps you can get close, but it still shows the "mangled" class name in the HTML.
But with a dev/prod environment, you can have your cake and eat it too (for the most part). In dev we have our classnames be in the format of `[classname]---[file-path]---[filename]---[partial-hash]` So one of my classnames from a current project is `.container` in the file, but shows up as `.container---src-components-scanner----styles---1446d`. And in production shows up as `._1533JgnvGu096C2bCAkrxT`.