You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, blink doesn't seem to respect LSP suggestion ordering, defaulting to sorting by kind or label even when disabled in the config. This affects heuristic LSP suggestion ordering, such as enum variant suggestions within match blocks as demonstrated below.
How can I preserve LSP suggestion ordering as an end user?
Could we make LSP suggestion ordering the default behavior for blink.cmp? For reference, Zed implements this using a hybrid approach:
// We do want to strike a balance here between what the language server tells us
// to sort by (the sort_text) and what are "obvious" good matches (i.e. when you type
// `Creat` and there is a local variable called `CreateComponent`).
// So what we do is: we bucket all matches into two buckets
// - Strong matches
// - Weak matches
// Strong matches are the ones with a high fuzzy-matcher score (the "obvious" matches)
// and the Weak matches are the rest.
//
// For the strong matches, we sort by our fuzzy-finder score first and for the weak
// matches, we prefer language-server sort_text first.
//
// The thinking behind that: we want to show strong matches first in order of relevance(fuzzy score).
// Rest of the matches(weak) can be sorted as language-server expects.
The text was updated successfully, but these errors were encountered:
This issue has largely been resolve with 76230d5 but the Zed hybrid sort seems quite interesting. I don't have the time to work on it right now, but I've thrown up a draft PR for anyone interested in working on the sorting. You can open a PR against that branch
Feature Description
Currently, blink doesn't seem to respect LSP suggestion ordering, defaulting to sorting by kind or label even when disabled in the config. This affects heuristic LSP suggestion ordering, such as enum variant suggestions within match blocks as demonstrated below.
VsCode:
Zed:
Blink:
My blink config:
My questions are:
How can I preserve LSP suggestion ordering as an end user?
Could we make LSP suggestion ordering the default behavior for blink.cmp? For reference, Zed implements this using a hybrid approach:
The text was updated successfully, but these errors were encountered: