-
Notifications
You must be signed in to change notification settings - Fork 360
Description
Excluding v0.13.0 (due to the issue outlined in #776 & #777), Microbundle can end up using the JS format in the CSS file's name. For example, imagine I have the following keys in my package.json:
{
"main": "dist/index.js",
"module": "dist/index.module.js",
"exports": "dist/index.modern.js",
"umd:main": "dist/index.umd.js",
}
If I were to run Microbundle with microbundle build -f modern, then only index.modern.js will be in my output, but also causes index.modern.css to be generated. In most cases this likely wouldn't be an issue, as if I was targeting only modern I'd likely have it represented by index.js (remove the modern specifier altogether) but it is a side case that can emerge.
This is less than ideal as it's pointless in the case of Modern & UMD; confusing in the case of ESM as index.module.css does carry a different meaning.
Should be simple enough to edit the extract logic for rollup-plugin-postcss.