-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
require
of package with CJS exports.require
and ESM main
fails with ERR_REQUIRE_ESM
after any quibble
#110
Comments
Doing a bit more digging, I found that this is due to the Line 223 in 1afc5fb
This is arguably a misconfigured So I don't think this is a bug in quibble since |
require
of package with conditional exports fails with ERR_REQUIRE_ESM
after any quibblerequire
of package with CJS exports.require
and ESM main
fails with ERR_REQUIRE_ESM
after any quibble
A dependency with
a CJStype: "module"
and conditional exports where thedefault
is ESM and therequire
is CJSexports["."].require
and an ESMmain
will fail with anERR_REQUIRE_ESM
error after any call toquibble()
.This reproduces for me with the latest version of quibble (0.9.2) and the latest version of Node 18 (18.20.1) an 20 (20.12.1).
Reproduction
Save the following bash script as
repro.sh
to an empty directory and run it withbash repro.sh
:The text was updated successfully, but these errors were encountered: