What does HackerNews think of ocaml-lsp?

OCaml Language Server Protocol implementation

Language: OCaml

> There is no alternative to Django, for instance.

https://aantron.github.io/dream/, which is new and used by ocaml.org as well as OP

> No serious IDE, except emacs

and vim, and visual studio, and whatever else supports the LSP protocol via https://github.com/ocaml/ocaml-lsp

> The standard library was so lacking that there is at least an alternative.

While janestreet does have an publish their own stdlib, I personally try to stick to the stdlib whenever possible. Not to knock janestreet. I'm glad they're around and have contributed a bunch.

But overall I agree with you. It's been my favorite language to write in for years now. You can't just reach for off-the-shelf libraries for every little thing. Although the ones that do exist tend to be written halfway decently.

If you are using vscode or any other editor that supports the Language Server Protocol [1], ocaml has an excellent LSP offering [2] now that is built on top of merlin. There is a vscode plugin available as well [3].

[1] https://microsoft.github.io/language-server-protocol/

[2] https://github.com/ocaml/ocaml-lsp/

[3] https://marketplace.visualstudio.com/items?itemName=ocamllab...

Perhaps the README[1] is out of date, but it appears to note that textDocument/implementation is not done? That's a pretty big hole.

[1]: https://github.com/ocaml/ocaml-lsp/#features

OCaml has a pretty decent language server [1]. You can pair it with the excellent OCaml vscode plugin [2], or any other LSP plugin for the editor of your choice.

[1] https://github.com/ocaml/ocaml-lsp/

[2] https://marketplace.visualstudio.com/items?itemName=ocamllab...

> The last time I tried neovim the LSP kept crashing for me on random occasions, some plugins had considerable performance issues, some things weren't async, and so forth.

Any issues with the language server I doubt are client side, and every request/response is "async".

For a minimum setup it is:

1. Install the language server via opam:

  opam pin add ocaml-lsp-server https://github.com/ocaml/ocaml-lsp.git

  opam install ocaml-lsp-server
2. Add lspconfig, the plugin

3. Add the following to your init.lua

  require'lspconfig'.ocamllsp.setup{}
4. That will give you basic linting, you can add keybindings/omnifunc integrations by copying out our configuration examples from `:help lspconfig` or the lspconfig wiki.

We're not trying to target vscode users, so if the above is too many steps that is ok, you just aren't our target audience.