-
Notifications
You must be signed in to change notification settings - Fork 13.1k
Open
Labels
Needs InvestigationThis issue needs a team member to investigate its status.This issue needs a team member to investigate its status.
Description
Bug Report
NodeNext resolution failed to resolve dual-package correctly
π Search Terms
NodeNext
π Version & Regression Information
- Never worked
π» Code
https://github.com/Jack-Works/ts-nodenext-wrong-resolution-reproduction
where node_modules/testpkg/package.json is
{
"name": "testpkg",
"exports": {
".": {
"types": "./dist/type.d.ts",
"require": "./dist/common.cjs",
"import": "./dist/module.mjs"
}
}
}TypeScript should resolve type.d.ts in dual mode instead of CommonJS synthetic export.
π Actual behavior
src/index.ts:2:1 - error TS2349: This expression is not callable.
Type 'typeof import("testpkg/dist/type")' has no call signatures.
π Expected behavior
No error
stevenwdv, gunters63, AlexAegis, n-p-e, ruyadorno and 6 more
Metadata
Metadata
Assignees
Labels
Needs InvestigationThis issue needs a team member to investigate its status.This issue needs a team member to investigate its status.