From d7b9682612e514307123002d88ec24a413871bec Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Mon, 4 Feb 2019 15:12:44 +0000 Subject: Emacs: Fix LSP setup --- emacs/.emacs.d/main.el | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) (limited to 'emacs/.emacs.d/main.el') diff --git a/emacs/.emacs.d/main.el b/emacs/.emacs.d/main.el index 3502f2ce..c6e81fee 100644 --- a/emacs/.emacs.d/main.el +++ b/emacs/.emacs.d/main.el @@ -1640,11 +1640,14 @@ With two prefix arguments, write out the day and month name." ;; Enable smart language features by communicating with an outside application. Neat. -(use-package lsp-mode) +(use-package lsp-mode + :commands lsp + :hook (js2-mode + typescript-mode)) -(use-package lsp-imenu - :config (progn - (add-hook 'lsp-after-open-hook #'lsp-enable-imenu))) +(use-package lsp-ui + :commands (lsp-ui-mode) + :config (add-hook 'lsp-after-open-hook #'lsp-enable-imenu)) (use-package company-lsp :after (company lsp-mode) @@ -1910,14 +1913,6 @@ With two prefix arguments, write out the day and month name." :config (progn (add-hook 'js2-mode-hook #'indium-interaction-mode))) -;;;;;; lsp-javascript - -(use-package lsp-javascript-typescript - :if (executable-find "javascript-typescript-langserver") - :config (progn - (remove-hook 'js2-mode-hook #'lsp-javascript-typescript-enable) - (add-hook 'typescript-mode-hook #'lsp-javascript-typescript-enable))) - ;;;;;; tide ;; Let's write some typescript -- cgit 1.4.1