0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Emacsにtypescript環境を設定する

Posted at

ちょっとtypescript書くことになったのでEmacsに設定を追加します。
私はパッケージ管理にstraight.elを使っているので、詳しくは前回の記事を参照ください。
Emacs環境をアップデートする(straight.el)

以下のパッケージを入れて、シンタックスハイライト、補完などできるようにします。

init.el
;; typescript
(straight-use-package 'typescript-mode)
(straight-use-package 'tide)
(add-to-list 'auto-mode-alist '("\\.ts\\'" . typescript-mode))
(add-hook 'typescript-mode-hook
          '(lambda ()
             (interactive)
             (tide-setup)
             (flycheck-mode +1)
             (tide-hl-identifier-mode +1)
             (company-mode +1)
             (eldoc-mode +1)
             ))
スクリーンショット 2020-05-15 16.09.56.png
0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?