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

Filtered out types from import suggestions in JS files #53619

Merged
merged 19 commits into from
Nov 16, 2023

Conversation

JoshuaKGoldberg
Copy link
Contributor

@JoshuaKGoldberg JoshuaKGoldberg commented Apr 1, 2023

When in a JS file (with the exception of JSDoc type imports), type-only declarations (interfaces and type aliases) are filtered out of completion entries.

Fixes #53339

Co-authored-by: Mateusz Burzyński mateuszburzynski@gmail.com

@typescript-bot typescript-bot added the For Backlog Bug PRs that fix a backlog bug label Apr 1, 2023
@JoshuaKGoldberg JoshuaKGoldberg marked this pull request as ready for review April 1, 2023 02:35
JoshuaKGoldberg and others added 2 commits April 4, 2023 19:46
Co-authored-by: Ryan Cavanaugh <RyanCavanaugh@users.noreply.github.com>
@JoshuaKGoldberg JoshuaKGoldberg marked this pull request as draft April 5, 2023 20:29
@JoshuaKGoldberg JoshuaKGoldberg marked this pull request as ready for review April 6, 2023 12:01
@JoshuaKGoldberg JoshuaKGoldberg marked this pull request as draft April 13, 2023 15:38
@JoshuaKGoldberg JoshuaKGoldberg marked this pull request as ready for review April 13, 2023 16:16
Copy link
Member

@sandersn sandersn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good although I had a couple of questions about the tests.

tests/cases/fourslash/jsFileImportNoTypes.ts Outdated Show resolved Hide resolved
Copy link
Member

@sandersn sandersn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Noticed a couple more things about symbolAppearsToBeTypeOnly

src/services/completions.ts Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
For Backlog Bug PRs that fix a backlog bug
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Filter out types from esm import suggestions in JavaScript
6 participants