A bare-bones implementation of a language server in Node.js. Ready to use as a template for your own experiments.
This language server can work with arbitrary text files and implements the following capabilities of the Language Server Protocol (LSP) out-of-the-box:
-
Completion. Provides completion items
Language
,Server
,Protocol
irrespective of the current document position. -
Diagnostics. Checks that the acronym
LSP
is spelled in the correct case and reports violations as warnings.
$ git clone https://github.com/lxtk-org/proto-language-server
$ cd proto-language-server/
$ npm install
$ npm run build
$ npm link
$ npx proto-language-server --stdio
$ npx --node-arg=--nolazy --node-arg=--inspect=6009 proto-language-server --stdio