From dd4ed825762d32ca9f791bda3bb9c459886c7061 Mon Sep 17 00:00:00 2001 From: Daniel Perez Alvarez Date: Thu, 24 Jun 2021 21:36:23 -0400 Subject: docs(lsp): Add Emacs eglot lsp configuration example (#10006) Co-authored-by: John Spurlock --- docs/getting_started/setup_your_environment.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'docs/getting_started') diff --git a/docs/getting_started/setup_your_environment.md b/docs/getting_started/setup_your_environment.md index b78c25203..769528b74 100644 --- a/docs/getting_started/setup_your_environment.md +++ b/docs/getting_started/setup_your_environment.md @@ -184,6 +184,23 @@ project (`npm init -y` as necessary), then add the following block to your } ``` +You can also use built-in Deno language server by using +[`eglot`](https://github.com/joaotavora/eglot). + +Example configuration: + +```elisp +(add-to-list 'eglot-server-programs '((js-mode typescript-mode) . (eglot-deno "deno" "lsp"))) + + (defclass eglot-deno (eglot-lsp-server) () + :documentation "A custom class for deno lsp.") + + (cl-defmethod eglot-initialization-options ((server eglot-deno)) + "Passes through required deno initialization options" + (list :enable t + :lint t)) +``` + #### Atom Install [atom-ide-base](https://atom.io/packages/atom-ide-base) package and -- cgit v1.2.3