Closed lokimckay closed 2 years ago
Sorry about that, was missing .cjs
from the regex. Should be fixed when #919 is merged and released.
microbundle: 0.14.2 see the same error, does it published ??
No, that has not yet been published.
thanks @rschristian , when will publish it? is there a estimate time?
There's no ETA, no. You can use something like patch-package
to copy over the diff from #919 in the meantime.
@leohxj Just wanted to update you that v0.15 was just published containing this fix.
@rschristian thanks bro
Using a
.cjs
extension in themain
field ofpackage.json
(e.g."main": "./dist/foo.cjs"
) as per README causes microbundle to swallow any .css or .scss files importedReproduction steps
Repo: https://github.com/lokimckay-references/microbundle-883
npm init -y
npm install microbundle --save-dev
styles.css
andindex.js
filesimport "./styles.css"
withinindex.js
package.json
as per READMEsource
field to point toindex.js
npm run build
Actual output
Expected output
Workaround
Change the file extension of the
main
field from./dist/foo.cjs
->./dist/foo.js
= achieves expected output