-
Notifications
You must be signed in to change notification settings - Fork 32
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
[Question] Non-ESM Support #25
Comments
Aside from native ESM by using package.json type: module or loading from a .mjs instead of .js file, not sure. I recently leaned it's possible to start node with -r esm or -r esm-wallaby too. Then the project does not need to directly depend on esm. The esm library is still widely used. The esm-wallaby library is a fork of esm but adds optional-chaining (elvis), so that's mostly what I'm using these days. I haven't switched to native esm because of the limitations on code modification which is needed for sinon stubs/spies and newrelic agent to instrument code. Been trying to identify solutions to those issues, but currently unaware of alternatives that won't require major refactoring. |
@tcollinsworth Thank you for your time and great explanation, looking forward to using this library to resolve dns issues! |
Can't get this to work w/ jest due to the module exporting ESM |
ugh |
You can dynamically load ESM module before loading this module. Alternatively, if you are using native esm, I could create a native esm version. |
Is there a way to use this library without ESM, which has been abandoned for a long time?
The text was updated successfully, but these errors were encountered: