React Monaco Editor x Kotlin Language Server (websockets) showcase
September 15, 2023 ยท View on GitHub
This is a sample project that demonstrates how to use React Monaco Editor with Kotlin Language Server via websocket connection.
Quick Start
npm i # install dependencies for both server and client
npm run start:server # run websocket server to communicate with Kotlin Language Server
npm run dev # run React app
How it works
Websocket server creates a websocket connection between React app and Kotlin Language Server executable, converting json-rpc messages to websocket messages and vice versa. Worth mentioning that monaco editor doesn't support language clients out of the box, so this library is using monaco-languageclient lib to cover this case painlessly.
Notes
For simplicity, Kotlin Language Server executables has been git-tracked in this repository. You may also build and use the latest version from here.