-
Notifications
You must be signed in to change notification settings - Fork 1.7k
fix: set the right postfix snippets competion source range #17000
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
Conversation
Changed the completion item source_range to match the replaced text. Though in VS Code it may not be disturbing because the snippet is previewed in a box, but in Helix editor, it's previewed by applying the main text edit.
Thanks! |
☀️ Test successful - checks-actions |
thanks for working on this! I just wanted to say that this doesn't just fix the preview (which is just a visual thing) but also multicursor completions. Additional text edits can't be mapped to multiple cursor (since they aren't associated with the cursor. The spec actually considers this use case. You don't want to repeat imports for each cursor for example). I see that RA does this as a workaround for LSP only allowing a single edit to each completion item. I think that generally makes sense for associated edits like imports but I can't think of a practical case where multiple edits would be associated with each cursor. I suspect the RA completion edit could be brought closer to the lsp completion edit and avoid impedance mismatches like this bug |
Hi 👋,
Changed the completion item
source_range
to match the replaced text. Though in VS Code it may not be disturbing because the snippet is previewed in a box, but in Helix editor, it's previewed by applying the main text edit.Before :

After :

Thanks