[Feature] - Support for node --conditions
flag in subpath imports
#5171
Labels
enhancement
New feature or request
--conditions
flag in subpath imports
#5171
Describe the user story
A package can contain subpath imports as declared here.
Then I should be able to require that content via:
const something = require("#hax");
. That syntax there works just fine, but not if you specify the node cli option--conditions
. For example, I should be able to declare:hax.js
hax_default.js
test.js
Using the setup above if I execute:
This indicates that the yarn berry loader isn't properly utilizing the
--conditions
flag of Node.Tested on:
node: v16.18.0
yarn: 3.2.4
This does not happen if I utilize
nodeLinker: "node-modules"
. It works correctly in that situation.The text was updated successfully, but these errors were encountered: