From 3d33da474ec888e5de6a2c175606e6873b70e6a0 Mon Sep 17 00:00:00 2001 From: mattkae Date: Mon, 26 Sep 2022 21:29:06 -0400 Subject: Using tide in typescript for refactoring --- lisp/web.el | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lisp/web.el b/lisp/web.el index a161e0f..7ec4af3 100644 --- a/lisp/web.el +++ b/lisp/web.el @@ -59,6 +59,13 @@ (add-hook 'typescript-mode-hook #'setup-ts-mode) (add-hook 'typescriptreact-mode-hook #'setup-ts-mode) +;; Tide for refactoring +(defun setup-tide-mode() + (tide-setup) + (local-set-key [f2] 'tide-rename-symbol) +) +(add-hook 'typescript-mode-hook #'setup-tide-mode) + ;; Package management (use-package eglot :custom -- cgit v1.2.1