Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to generate a Visual Studio Code extension with C#?

I am working on adding a new language support to vscode, and I have finished a debugger with C#, but this is modified from the mono-debugger sample provided in vscode document. Now I would like to make a language service, so I would like to know if it is possible to do it with C#?

like image 278
Arphone Pei Avatar asked Oct 17 '25 09:10

Arphone Pei


1 Answers

This is possible if you use an abstraction layer called the Language Server Protocol. Theoretically, it gives you the freedom to implement language support in any language that supports socket communication. You will still need a VSCode extension in JS that starts the language server, but it doesn't need to do much beyond that.

A few examples:

  • Java Language Server implemented in Java
  • Python Language Server implemented in Python
  • C/C++ Language Server implemented in C++
  • etc.

When writing a language server, you will also need a library that actually implements the protocol part of it. Looks like for C# one already exists.

like image 102
Gama11 Avatar answered Oct 18 '25 22:10

Gama11



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!