eclipse-lsp4j / lsp4j

A Java implementation of the language server protocol intended to be consumed by tools and language servers implemented in Java.

Home Page:https://eclipse.org/lsp4j

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

vtsls and typescript-language-server don't retrieve all references when trying to retrieve code references

andy-wong-andy-wong opened this issue · comments

I'm not sure if this is a vtsls/typescript-language-server issue, or a LSP4J issue, but it seems like there are some references that don't get captured when I try to access the code references via LanguageServer.textDocumentService.references.

However, this only retrieves the first reference of the variable. There are other instances of the references that are not retrieved. The particular issue is in a React Typescript file. The file contains the following:

val variableName = true

... many lines down...

{ variableName &&
...

LSP4J only seems to capture the first reference, and does not grab the second instance.

Lsp4j is just a protocol transport impl. So I assume the problem is either in your client or server impl.
Hoes does the response json look like ?

If you can provide the raw JSON here to demonstrate what is happening we can look more. For now I am going to close this issue.