Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Convert to custom Suggestion type & filter text with filterText key #262

Merged
merged 5 commits into from
Mar 5, 2019

Conversation

Aerijo
Copy link
Contributor

@Aerijo Aerijo commented Mar 5, 2019

Converts the internal uses of ac.AnySuggestion to the new Suggestion, which is an extended version of the original. In particular, it has the property filterText, used for custom filtering. It also makes it easier to add features, such as the replacement prefix tracking in #254

Regarding filtering using filterText, it seems not even VS Code had a solid idea on the difference between filterText and sortText for a time

The latest I could find is in that last issue, where they say [paraphrasing] "use sort text for no prefix" and "use filterText for when there's a prefix" (and they base on other things like match index). The source code also supports using filterText to sort as well when there's a prefix.

@Aerijo
Copy link
Contributor Author

Aerijo commented Mar 5, 2019

@50Wliu The package-lock.json looks quite different to the one you committed earlier, specifically the version range symbols have been removed. Is this fine?

@50Wliu
Copy link
Contributor

50Wliu commented Mar 5, 2019

Yeah, that's fine. Just commit whatever the result of npm install is.

@Aerijo Aerijo merged commit b60c543 into atom:master Mar 5, 2019
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