Last active
August 29, 2015 14:15
-
-
Save dgellow/6353f5e5693c7e1461a1 to your computer and use it in GitHub Desktop.
Configure mmm-mode for React, using js2-mode for javascript and web-mode for JSX.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require 'mmm-mode) | |
(mmm-add-classes | |
'((jsx | |
:submode web-mode | |
:front "\\((\\)[[:space:]\n]*<" | |
:front-match 1 | |
:back ">[[:space:]\n]*\\()\\)" | |
:back-match 1))) | |
(setq mmm-global-mode 'maybe) | |
(mmm-add-mode-ext-class 'js2-mode "\\.jsx\\'" 'jsx) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thank you!