diff options
author | Matthew Kosarek <mattkae@protonmail.com> | 2022-11-09 08:14:23 -0500 |
---|---|---|
committer | Matthew Kosarek <mattkae@protonmail.com> | 2022-11-09 08:14:23 -0500 |
commit | f1b5b5680cd582430c159db9ebff5ff5da338cb2 (patch) | |
tree | bbf963113ead0146e8c16dc42aa9b48547cb7d69 | |
parent | 5270f0e00daea72a8db39f1afcde984904060783 (diff) |
Improvement on the organizatin of eglot
-rw-r--r-- | lisp/general.el | 7 | ||||
-rw-r--r-- | lisp/web.el | 17 |
2 files changed, 12 insertions, 12 deletions
diff --git a/lisp/general.el b/lisp/general.el index 7dd50f8..31e9019 100644 --- a/lisp/general.el +++ b/lisp/general.el @@ -224,6 +224,13 @@ ) ) +;; Eglot +(use-package eglot + :custom + (eglot-autoshutdown t) + :ensure t + :defer 3) +(set-face-background 'eglot-highlight-symbol-face "lemon chiffon") ;; Vterm (require 'vterm) diff --git a/lisp/web.el b/lisp/web.el index b076147..e71673d 100644 --- a/lisp/web.el +++ b/lisp/web.el @@ -81,18 +81,11 @@ (add-hook 'flycheck-mode-hook #'my-use-eslint-from-node-modules) ;; Package management -(use-package eglot - :custom - (eglot-autoshutdown t) - :ensure t - :defer 3 - :hook - ((js-mode typescript-mode) . eglot-ensure)) - :config - (cl-pushnew '((js-mode typescript-mode) . ("typescript-language-server" "--stdio")) - eglot-server-programs - :test #'equal) -(set-face-background 'eglot-highlight-symbol-face "lemon chiffon") +(require 'eglot) +(add-hook 'js-mode-hook 'eglot-ensure) +(add-hook 'typescript-mode-hook 'eglot-ensure) +(add-to-list 'eglot-server-programs '(js-mode . ("typescript-language-server" "--stdio"))) +(add-to-list 'eglot-server-programs '(typescript-mode . ("typescript-language-server" "--stdio"))) ;; Ignore certain directories in projectile (require 'projectile) |