summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAlan Pearce2016-01-14 19:26:51 +0100
committerAlan Pearce2016-01-14 19:26:51 +0100
commit142e29561966e9a991145947b52a763f9906658c (patch)
tree56dde85274f0744906dfc7fde56f043a7cf289f8
parent10f81ec220477c7b8c7ea637639f78e90c7a4c3e (diff)
downloadnixfiles-142e29561966e9a991145947b52a763f9906658c.tar.lz
nixfiles-142e29561966e9a991145947b52a763f9906658c.tar.zst
nixfiles-142e29561966e9a991145947b52a763f9906658c.zip
Emacs: Use js2-mode for jsx files
-rw-r--r--tag-emacs/emacs.d/init.org6
1 files changed, 3 insertions, 3 deletions
diff --git a/tag-emacs/emacs.d/init.org b/tag-emacs/emacs.d/init.org
index 2c861433..7eff008b 100644
--- a/tag-emacs/emacs.d/init.org
+++ b/tag-emacs/emacs.d/init.org
@@ -1940,7 +1940,8 @@ it though
 
 #+BEGIN_SRC emacs-lisp
   (use-package js2-mode
-    :mode ("\\.js\\'" . js2-mode)
+    :mode (("\\.js\\'" . js2-mode)
+           ("\\.jsx\\'" . js2-jsx-mode))
     :functions js2-next-error
     :config (progn
               (defun ap/javascript-setup ()
@@ -2043,8 +2044,7 @@ of them as well.
     :mode (("/views/.*\\.php\\'" . web-mode)
            ("/layouts/.*\\.html\\'" . web-mode)
            ("/templates/.*\\.php\\'" . web-mode)
-           ("\\.ejs\\'" . web-mode)
-           ("\\.jsx\\'" . web-mode))
+           ("\\.ejs\\'" . web-mode))
     :config (setq web-mode-code-indent-offset 4
                   web-mode-css-indent-offset 4
                   web-mode-markup-indent-offset 4