summary refs log tree commit diff stats
path: root/emacs/.emacs.d/main.el
diff options
context:
space:
mode:
Diffstat (limited to 'emacs/.emacs.d/main.el')
-rw-r--r--emacs/.emacs.d/main.el7
1 files changed, 6 insertions, 1 deletions
diff --git a/emacs/.emacs.d/main.el b/emacs/.emacs.d/main.el
index bb902583..2f7bf539 100644
--- a/emacs/.emacs.d/main.el
+++ b/emacs/.emacs.d/main.el
@@ -2296,7 +2296,12 @@ With prefix TO-CURRENT-BUFFER, insert command output into buffer."
 ;; #+BEGIN_SRC emacs-lisp
 (use-package add-node-modules-path
   :config (progn
-            (add-hook 'js2-mode-hook #'add-node-modules-path)))
+            (define-hook-helper js2-mode ()
+              (add-node-modules-path)
+              (when (executable-find "eslint")
+                (setq flycheck-javascript-eslint-executable "eslint"))
+              (when (executable-find "standard")
+                (setq flycheck-javascript-standard-executable "standard")))))
 ;; #+END_SRC
 
 ;; ***** Flow