LanguageServer.NET icon indicating copy to clipboard operation
LanguageServer.NET copied to clipboard

How to intergate with monaco editor

Open GNSubrahmanyam opened this issue 4 years ago • 6 comments

https://github.com/TypeFox/monaco-languageclient

GNSubrahmanyam avatar Jun 16 '20 18:06 GNSubrahmanyam

Are you using nodejs/Electron or browser?

CXuesong avatar Jun 17 '20 01:06 CXuesong

Browser monaco editor

GNSubrahmanyam avatar Jun 17 '20 12:06 GNSubrahmanyam

is this language server production ready?

GNSubrahmanyam avatar Jun 17 '20 12:06 GNSubrahmanyam

Browser monaco editor

TypeFox LSP client is using WebSocket for communication; thus you may try using this project with CXuesong.JsonRpc.WebSockets package in CXuesong/JsonRpc.Standard for C# server-side implementation. I have a project demonstrating how to host JSON-RPC server over HTTP and WebSocket here. Still, you may need to investigate on whether it's possible to piece all the parts together.

If you see any issues with C# LSP server over WebSocket, consider opening an issue there.

Please note that this project only contains JSON contract classes so that you won't need to repeat the work of writing them by yourself in C#.

is this language server production ready?

As I've said in README, I started this project a while ago in the hope of writing a wikitext LSP server for VSCode. Unfortunately the downstream project is in stasis so I really don't have any reason to keep updating in a self-motivated fashion. Having said that, if you happen to choose this library, I'll be glad to help.

CXuesong avatar Jun 21 '20 05:06 CXuesong

前台代码展示区用Monaco editor,代码路径固定,能否直接注册并用这个LSP完成一些代码跳转等基础功能?

zhizhixiongxuwei avatar Jun 30 '20 04:06 zhizhixiongxuwei

@zhizhixiongxuwei 你打算用什么传输方式承载JSON RPC消息呢?请注意“跳转到定义”本身其实是不一定需要LSP的,你只需要在monaco-editor中订阅对应的事件即可。

CXuesong avatar Jul 01 '20 14:07 CXuesong