Use 'label' phase instead of 'debug' phase to extract css
ajoslin opened this issue · 2 comments
If people use bundle-collapser, the string 'insert-css' is replaced with a number.
Since bundle-collapser is run in the label phase and css-extract is run afterwards the debug phase, no css is extracted -- no insert-css strings exist in the code after bundle-collapser runs.
Since we rely on module names being strings and since bundle-collapser is such a common plugin to use (IMO), I think running before the label phase is reasonable.
Is there a separate line of reasoning for the debug phase being chosen?
I believe we chose the debug phase to ensure it's one of the last things that runs. We didn't account for bundle-collapser possibly conflicting with this - I'm cool with changing debug to label.
Perfect! I'll open a PR soon.