DEV Community

Cover image for Setup OCaml With NeoVim

Setup OCaml With NeoVim

Sophia Brandt on November 10, 2019

How to use the NeoVim text editor as your Ocaml IDE Why OCaml? I've always been interested in learning an ML language. But Haskell, t...
Collapse
 
yawaramin profile image
Yawar Amin

Good guide. Btw for the esy setup you don't need opam and opam install merlin because as you mentioned if you start the editor with esy it will automatically set up the merlin that's in your project's devDeps.

Collapse
 
sophiabrandt profile image
Sophia Brandt

Thanks. That's good to know. I will update the guide.

Collapse
 
ryskajakub profile image
Jakub Ryška

Can you enumerate the features it does have? Last time I tried to use merlin with native ocaml it was hard to jump to source, for example to core, it was all red with errors and it only worked when the source was compilable, as soon as the source file didn't compile, there were no type inspections, no go to source etc. I'm eager to see experience of others in this area

Collapse
 
sophiabrandt profile image
Sophia Brandt • Edited

Jump to definition/source works for me. Also auto-completion.
But I had problems with Reason code where Merlin tends to interfere.
I've switched to the reason language server for now. But for ocaml it doesn't work that great.
Esy is an alternative.

Collapse
 
rohansawant profile image
Rohan Sawant

Going in I had no idea what any of the words in your title meant, now...I am enlightened ☺

🔥!

Collapse
 
sophiabrandt profile image
Sophia Brandt • Edited

Thanks Rohan.
Good point. I didn't mention that NeoVim is an editor (a Vim spin-off). I'll add it.

Collapse
 
avelino profile image
Thiago Avelino