compiled
compiled copied to clipboard
[webpack] Atomic stylesheet isn't optimized unless it ends in "compiled-css.css"
Suspect code is here https://github.com/atlassian-labs/compiled/blob/master/packages/webpack-loader/src/extract-plugin.tsx#L25
We want to identify the CSS asset so we only optimize the "compiled css" one. We use cache groups to force the styles into a single group (see: https://github.com/atlassian-labs/compiled/blob/master/packages/webpack-loader/src/extract-plugin.tsx#L39).
Optimization falls over when the name is [contenthash].css or the like, because now we can't identify what the cache group is.
What could a potential fix be?