Fix typescript language server on emacs
This commit is contained in:
parent
2a6daaafbb
commit
06a0610eee
@ -207,7 +207,7 @@
|
|||||||
:hook (;; replace XXX-mode with concrete major-mode(e. g. python-mode)
|
:hook (;; replace XXX-mode with concrete major-mode(e. g. python-mode)
|
||||||
(elixir-mode . lsp)
|
(elixir-mode . lsp)
|
||||||
(rust-mode . lsp)
|
(rust-mode . lsp)
|
||||||
(typescript-mode . lsp)
|
(typescript-mode . lsp) ;; npm install -g typescript typescript-language-server
|
||||||
;; if you want which-key integration
|
;; if you want which-key integration
|
||||||
(lsp-mode . lsp-enable-which-key-integration))
|
(lsp-mode . lsp-enable-which-key-integration))
|
||||||
:commands lsp)
|
:commands lsp)
|
||||||
@ -254,12 +254,12 @@ After installing the ~rust-analyzer~ program, the following can be used:
|
|||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
(use-package prettier-js
|
(use-package prettier-js
|
||||||
:ensure t)
|
:ensure t)
|
||||||
(add-hook 'web-mode-hook #'(lambda ()
|
(add-hook 'js2-mode-hook 'prettier-js-mode)
|
||||||
(enable-minor-mode
|
(add-hook 'web-mode-hook 'prettier-js-mode)
|
||||||
'("\\.jsx?\\'" . prettier-js-mode))
|
|
||||||
(enable-minor-mode
|
|
||||||
'("\\.tsx?\\'" . prettier-js-mode))))
|
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
|
||||||
|
#+RESULTS:
|
||||||
|
|
||||||
*** Kotlin
|
*** Kotlin
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
(use-package kotlin-mode
|
(use-package kotlin-mode
|
||||||
|
Loading…
Reference in New Issue
Block a user