3 ms·
I mean, this is theoretically true, if an editor provided a language-agnostic protocol for talking to potential semantic plugins. The article says > Rather, a
by andrewla 5y ago
I mean, this is theoretically true, if an editor provided a language-agnostic protocol for talking to potential semantic plugins. The article says
> Rather, a language should implement a server which speaks some protocol, an editor needs to implement language agnostic APIs for providing completions and such, and, if both the language and the editor are not esoteric, someone who is interested in both would just write a bit of glue code to bind the two together
I mean, yes, ideally that is what should have happened, but the first editor to actually do that was VSCode, and the protocol it chose is called LSP, so that's where we are.
- afdbcreid 5y agoBut it doesn't need to be a protocol, just some API. And VSCode actually does that - I think it doesn't even have LSP builtin (but I may be wrong).
- matklad 5y agoYou are correct, and this is indeed one of the important facets I try to illuminate. VS Code doesn't support LSP natively, it just exposes a bunch of APIs to provide IDE features. Actual LSP support is implemented as a separate library on top of these API, an adapter pattern in the wild.