GithubHelp home page GithubHelp logo

Comments (5)

tcollinsworth avatar tcollinsworth commented on July 19, 2024 1

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.

from axios-cached-dns-resolve.

gaby avatar gaby commented on July 19, 2024

@tcollinsworth Thank you for your time and great explanation, looking forward to using this library to resolve dns issues!

from axios-cached-dns-resolve.

ozyman42 avatar ozyman42 commented on July 19, 2024

Can't get this to work w/ jest due to the module exporting ESM

from axios-cached-dns-resolve.

scythargon avatar scythargon commented on July 19, 2024

ugh
I need this too

from axios-cached-dns-resolve.

tcollinsworth avatar tcollinsworth commented on July 19, 2024

You can dynamically load ESM module before loading this module. Alternatively, if you are using native esm, I could create a native esm version.

from axios-cached-dns-resolve.

Related Issues (18)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.