-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Auto import suggests different paths based on if any import is exported in parent index.ts #46753
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
Comments
Duplicate of #45953 |
@andrewbranch It shows the absolute path in the auto import suggestion but gets the correct relative path selected. |
It broke in [email protected] |
@andrewbranch Probably this commit: |
This issue has been marked as a 'Duplicate' and has seen no recent activity. It has been automatically closed for house-keeping purposes. |
Issue Type: Bug
Auto import in VS Code suggests different import paths for export from the same source file if any of the exports are re-exported in for example the library's entry point. When working with our library we want to import from the source file in the library and not the entry point exposing thing for consumers. We use project-relative as Import Module Specifier since we have a monorepo using paths. But we have tried every setting without luck.
This is relatively new behavior, but I can't say exactly when it started to occur.
Repro:
https://github.com/JonWallsten/vscode-repro
We are not interested in consuming our own entry point and would like the imports to be the source file and not the entry point since it's for external consumer.
VS Code version: Code - Insiders 1.63.0-insider (b614fb5, 2021-11-09T10:02:27.095Z)
OS version: Windows_NT x64 10.0.19043
Restricted Mode: No
System Info
gpu_compositing: enabled
multiple_raster_threads: enabled_on
oop_rasterization: enabled
opengl: enabled_on
rasterization: enabled
skia_renderer: enabled_on
video_decode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
Extensions (9)
A/B Experiments
The text was updated successfully, but these errors were encountered: