Skip to content

feat(language-service): auto insert feature does not abstract selection#156

Merged
johnsoncodehk merged 2 commits intomasterfrom
auto-insert-improve
Apr 2, 2024
Merged

feat(language-service): auto insert feature does not abstract selection#156
johnsoncodehk merged 2 commits intomasterfrom
auto-insert-improve

Conversation

@johnsoncodehk
Copy link
Member

In the previous auto insertion implementation, @volar/vscode always issued requests with the end position of the changed range as a parameter. Based on whether the current selections include the end position of the changed range, it determines whether to insert the text into the selections or the end position of the changed range.

Now it is changed to always issue requests with the selection position and always insert the text into the selections. LanguageServicePlugin are responsible for determining whether the selection is at the end position of the changed range to determine whether to provide auto insert text.

This will resolve the limitation of not being able to achieve vuejs/language-tools#4140 downstream.

@johnsoncodehk johnsoncodehk merged commit 8afff8e into master Apr 2, 2024
@johnsoncodehk johnsoncodehk deleted the auto-insert-improve branch April 2, 2024 09:32
johnsoncodehk added a commit to volarjs/services that referenced this pull request Apr 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant