diff options
author | Alan Pearce | 2018-09-07 17:10:04 +0200 |
---|---|---|
committer | Alan Pearce | 2018-09-07 17:10:04 +0200 |
commit | 2c275841789ae9558585646cec3e18cad292f603 (patch) | |
tree | 101fdb9b27e2bf772c7aff47e52b4b1d1cc580cb /emacs/.emacs.d | |
parent | e1834dda554a1f108d7a17588571191417f7d15e (diff) | |
download | nixfiles-2c275841789ae9558585646cec3e18cad292f603.tar.lz nixfiles-2c275841789ae9558585646cec3e18cad292f603.tar.zst nixfiles-2c275841789ae9558585646cec3e18cad292f603.zip |
Emacs: Configure prettier-js
Diffstat (limited to 'emacs/.emacs.d')
-rw-r--r-- | emacs/.emacs.d/main.el | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/emacs/.emacs.d/main.el b/emacs/.emacs.d/main.el index 65eae69a..cdd65dab 100644 --- a/emacs/.emacs.d/main.el +++ b/emacs/.emacs.d/main.el @@ -2024,6 +2024,15 @@ With two prefix arguments, write out the day and month name." (when (executable-find "standard") (setq-local flycheck-javascript-standard-executable (executable-find "standard")))))) +;;;;;;; Prettier + +;; Reformat files on save + +(use-package prettier-js + :config (progn + (add-hook 'typescript-mode #'prettier-js-mode) + (add-hook 'js2-mode #'prettier-js-mode))) + ;;;;;;; Indium ;; Javascript with an inferior node.js process and a debugger? Awesome. |