Skip to content

[typescript-language-features] Support import statement completions for TypeScript 4.3 #119009

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

Merged

Conversation

andrewbranch
Copy link
Member

Counterpart of microsoft/TypeScript#43149 (cc @mjbvz)

@mjbvz
Copy link
Collaborator

mjbvz commented Mar 19, 2021

Looks good to me! Will merge once the TS side of the fix is merged. VS Code endgame starts next week, so we'd probably want to target 1.56 insiders

@mjbvz mjbvz added this to the April 2021 milestone Mar 19, 2021
@@ -5,6 +5,8 @@
"configuration.typescript": "TypeScript",
"configuration.suggest.completeFunctionCalls": "Complete functions with their parameter signature.",
"configuration.suggest.includeAutomaticOptionalChainCompletions": "Enable/disable showing completions on potentially undefined values that insert an optional chain call. Requires TS 3.7+ and strict null checks to be enabled.",
"configuration.suggest.includeCompletionsForImportStatements": "Enable/disable auto-import-style completions on partially-typed import statements. Requires using TypeScript 4.3+ in the workspace.",
"configuration.suggest.includeCompletionsWithSnippetText": "Enable/disable snippet completions from TS Server. Requires using TypeScript 4.3+ in the workspace.",
Copy link
Member Author

Choose a reason for hiding this comment

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

Updated to add an explicit option for snippet-formatted completions, since clients that don’t expect them would insert literal $1 instead of tab stops.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Just as a future note: This is the first example where TS Server uses snippets, but I have a long standing TS issue about using snippets in more places: microsoft/TypeScript#25207

@andrewbranch
Copy link
Member Author

@mjbvz the TS PR is merged. Feel free to merge this one whenever you’re ready.

@mjbvz mjbvz merged commit 29ca249 into microsoft:main Mar 29, 2021
@mjbvz
Copy link
Collaborator

mjbvz commented Mar 29, 2021

Thanks!

@andrewbranch andrewbranch deleted the feature/import-statement-suggestions branch March 29, 2021 21:31
@github-actions github-actions bot locked and limited conversation to collaborators May 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants