Closed TheDevMinerTV closed 4 months ago
This is a huge one. resolve
is used in Jest and Babel, which are used in (as you said) pretty much every bundler.
Jest's rationale (https://github.com/jestjs/jest/pull/9520) is that it's faster than require.resolve()
and can support custom filesystem hooks to further increase performance. Other users may be using it for similar customizability reasons (async support, etc).
The require.resolve
algorithm is documented as pseudocode in Node's docs, and implemented as JS within Node itself.
This is a huge one.
resolve
is used in Jest and Babel, which are used in (as you said) pretty much every bundler. ... can support custom filesystem hooks to further increase performance.
Agreed, that's why I am hesitant about this.
https://npmgraph.js.org/?q=resolve
Also, the resolve
looks OK, as the only toxic dependency (so far) is the is-core-module
, which is discussed in #69.
Since nolyfill 1.0.32 introduces @nolyfill/is-core-module
, I am going to close the issue for now.
And feel free to create a new issue or ping me to re-open this one if HE WHO MUST NOT BE NAMED introduces other toxic dependencies to the resolve
!
resolve
is used by most bundlers and build tools, which causes it to get installed multiple times because of how npm in isolation mode works. I don't see the point in this library since it literally says it "implements Node'srequire.resolve()
".https://npm.anvaka.com/#/view/2d/resolve https://voldephobia.rschristian.dev/?q=resolve