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

Figure out how to encode sortText (because it means TypeScript deprecated completions show up first) #45288

Closed
DanielRosenwasser opened this issue Aug 2, 2021 · 1 comment · Fixed by #45292
Assignees
Labels
Bug A bug in TypeScript Domain: Completion Lists The issue relates to showing completion lists in an editor Fix Available A PR has been opened for this issue

Comments

@DanielRosenwasser
Copy link
Member

Try requesting completions in a blank file.

image

I think this is because our SortText uses numeric text, but the text is sorted as a string. Why would that matter? Well, global deprecated completions have a numeric value of 13, which is less than almost any other completion entry type.

Editors just do a basic string comparison of sortTexts, so we should figure out how to fix this.

@andrewbranch
Copy link
Member

We’ll need an entirely new scheme if we want to do #41083, which I plan on looking at for 4.5.

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: Completion Lists The issue relates to showing completion lists in an editor 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