Skip to content
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

No auto-imports from exports fields apart from . #47009

Closed
DanielRosenwasser opened this issue Dec 3, 2021 · 0 comments · Fixed by #47092
Closed

No auto-imports from exports fields apart from . #47009

DanielRosenwasser opened this issue Dec 3, 2021 · 0 comments · Fixed by #47092
Assignees
Labels
Bug A bug in TypeScript Domain: Auto-import Domain: Completion Lists The issue relates to showing completion lists in an editor Domain: ES Modules The issue relates to import/export style module behavior Fix Available A PR has been opened for this issue

Comments

@DanielRosenwasser
Copy link
Member

DanielRosenwasser commented Dec 3, 2021

//// @filename: ./node_modules/dependency/package.json
//// {
////     "type": "module",
////     "name": "dependency",
////     "version": "1.0.0"
////     "exports": {
////         ".": {
////             "types": "./lib/index.d.ts",
////         }
////         "./lol": {
////             "types": "./lib/lol.d.ts",
////         }
////     }
//// }

//// @filename: ./node_modules/dependency/lib/index.d.ts
//// export function fooFromIndex(): void;

//// @filename: ./node_modules/dependency/lib/lol.d.ts
//// export function fooFromLol(): void;

//// @filename: ./package.json
//// {
////     "type": "module",
////     "dependencies": {
////         "dependency": "^1.0.0"
////     }
//// }

//// @filename: ./src/foo.ts
//// import fooFrom/**/

Expected: completions for fooFromIndex and fooFromLol
Actual: completions for fooFromIndex and but not fooFromLol

@DanielRosenwasser DanielRosenwasser added Bug A bug in TypeScript Domain: Completion Lists The issue relates to showing completion lists in an editor Domain: ES Modules The issue relates to import/export style module behavior Domain: Auto-import labels Dec 3, 2021
@DanielRosenwasser DanielRosenwasser added this to the TypeScript 4.6.0 milestone Dec 3, 2021
@typescript-bot typescript-bot added the Fix Available A PR has been opened for this issue label Dec 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug A bug in TypeScript Domain: Auto-import Domain: Completion Lists The issue relates to showing completion lists in an editor Domain: ES Modules The issue relates to import/export style module behavior Fix Available A PR has been opened for this issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants