Fix :LspDenoDefinition
to handle correctly
#782
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Run
:LspDenoDefinition
twice at built-in keyword/function such asconsole
, the result of the second run is not processed correctly.Steps to reproduce
:LspDenoDefinition
and jump to definition:bdelete
:LspDenoDefinition
and not jump to definitionNote: I'm using latest deno(v2.1.1) but this may happen In old version such as 1.38.1.
Log
1st try
2nd try
I think this is because
did open
sent deno's virtual text document's uri to language server.It seems to be correct to fix the didOpen part, but it is currently too difficult, so I created this workaround.
@mattn
Could you review this. Any advices would be greatly appreciated 🙏
Before:
Kapture.2024-11-25.at.00.23.00.mp4
After:
Kapture.2024-11-25.at.00.24.25.mp4
Thank you.