[tide] fix regression caused by e3b6464649

fix jump handler
This commit is contained in:
Thanh Vuong 2020-11-24 21:18:35 -07:00 committed by Maximilian Wolff
parent c483818d7e
commit 4b3ab4052a
2 changed files with 3 additions and 6 deletions

View File

@ -63,11 +63,8 @@ Must be called by a layer using tide."
(eldoc-mode))
(defun spacemacs//tide-setup-jump-handle ()
"Loop through `tide-managed-modes' and set jump handlers for these modes."
(dolist (mode tide-managed-modes)
(add-to-list
(intern (format "spacemacs-jump-handlers-%S" mode))
'(tide-jump-to-definition :async t))))
"Set jump handlers."
(add-to-list 'spacemacs-jump-handlers '(tide-jump-to-definition :async t)))
(defun spacemacs//tide-create-jsconfig-file ()
"Create a jsconfig file at project root."

View File

@ -19,4 +19,4 @@
:commands (typescript/jump-to-type-def)
:config
(spacemacs//tide-setup-bindings)
(spacemacs//tide-setup-jump-handle)))
(add-hook 'tide-mode-hook #'spacemacs//tide-setup-jump-handle)))