Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

In-browser editors #274

hatemhosny started this conversation in Ideas
Mar 30, 2025 · 2 comments · 3 replies
Discussion options

Great work. Thank you very much for such a great project.

Would you consider adding the LSP to Monaco editor and/or CodeMirror?
This allows running it in the browser (e.g. in playgrounds and cloud IDEs).

I believe there is an intention to provide a wasm integration. Would this allow such use?

Thank you.

You must be logged in to vote

Replies: 2 comments 3 replies

Comment options

I still need to look into this properly, but afaik Monaco can connect to a remote language server and that would make it possible already today.

The Wasm build would enable us to run the server within the browser too. However, we cannot connect to a real database due to browser restriction. My goal here is to connect to a Pglite instance eventually.

You must be logged in to vote
3 replies
Comment options

New to lsp implementation but I tried connecting it with Codemirror and could not get autocomplete to work. Would love if you can share a small snippet for CodeMirror or Monaco.

Comment options

Did you check this repo? https://github.com/TypeFox/monaco-languageclient

It seems to provide exactly the bridge you need.

Comment options

You may find this useful for codemirror6
https://github.com/FurqanSoftware/codemirror-languageserver

Also, this implements TypeScript autocomplete, lint and hover info for codemirror6. However they did not use LSP
https://github.com/val-town/codemirror-ts

Comment options

for whatever it's worth, as soon as a wasm build is published I plan to integrate it into https://postgres.garden

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

AltStyle によって変換されたページ (->オリジナル) /