apm install ocaml-merlin
Use ocamlmerlin to autocomplete, lint, refactor and navigate your OCaml/Reason code in Atom.
- Context-sensitive autocompletion and linting
- Show the type of expressions under the cursor
- Find all occurrences of a variable
- Jump to (type) declarations and back
- Shrink and grow selections in a smart way
- Rename all occurrences of a variable in a file
- Destruct expressions in pattern matchings
Linting is performed on save or while typing by linter. Autocompletion is performed on the fly by autocomplete-plus.
No default keybindings are provided, except those compatible with the
symbols-view package. Additional keybindings can be set in your keymap.
|Command||Description||Keybinding (Linux, Windows)||Keybinding (OS X)|
||Toggle type of expression under cursor|
||Shrink the expression|
||Expand the expression|
||Toggle the type bubble|
||Destruct expression under cursor|
||Find next occurrence of expression|
||Find previous occurrence of expression|
||Go to declaration of expression||ctrl-alt-down||cmd-alt-down|
||Go to type declaration of expression|
||Go back to expression||ctrl-alt-up||cmd-alt-up|
||Shrink the current selection|
||Expand the current selection|
||Rename all occurrences of variable|
This package requires language-ocaml, linter and ocamlmerlin. For auto-indenting destructed patterns, ocaml-indent is needed. For Reason support, language-reason is needed, and reason-refmt is recommended.
apm install language-ocaml linter ocaml-indent
opam install merlin