monaco-languageclient
monaco-languageclient copied to clipboard
How is goto definition for remote URIs supposed to be handled by monaco-languageclient
Hi! I wanted to ask whether there's some "idiomatic" way for the following scenario with monaco-languageclient:
- a languageserver is running on a backend
- the user uses goto definition to a definition that is located on a
file:URI on the backend.
Currently nothing is happening when I do this. Ideally I would like the frontend to load this file into a new buffer.
Any error in the console? you probably have a file not found error. You'll have to implement a provider able to get that file content from the backend
@CGNonofr, sadly no error at all, it just "doesn't work" (while it does work locally, in vscode)
I'm not sure an error is displayed if the file doesn't exists though. What is sure is that it needs a way to get the actual file content
Yes - do you have a pointer on where to start to get the file contents somehow?
It still should be done manually (related to https://github.com/TypeFox/monaco-languageclient/issues/834)
you can use the registerFileSystemOverlay method from @codingame/monaco-vscode-files-service-override to register your filesystem which will fetch the file content by any mean you want
thank you!
I will close this when I found a solution and will post it here for future reference.
Issue review before new release. I will close this now. @MangoIV feel free to post a solution later.