From d5d0ec3c919e4eb11c78743788717ee657604b4b Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Mon, 18 May 2020 14:38:02 -0400 Subject: [PATCH] Prioritize vue-mode over web-mode for *.vue files --- modules/lang/web/+html.el | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/modules/lang/web/+html.el b/modules/lang/web/+html.el index c3d73481c..eb0004811 100644 --- a/modules/lang/web/+html.el +++ b/modules/lang/web/+html.el @@ -10,7 +10,6 @@ :mode "\\.hbs\\'" :mode "\\.mustache\\'" :mode "\\.svelte\\'" - :mode "\\.vue\\'" :mode "\\.twig\\'" :mode "\\.jinja2?\\'" :mode "wp-content/themes/.+/.+\\.php\\'" @@ -19,6 +18,12 @@ ;; does not officially support JSX/TSX. See ;; https://github.com/emacs-typescript/typescript.el/issues/4 :mode "\\.tsx\\'" + :init + ;; If the user has installed `vue-mode' then, by appending this to + ;; `auto-mode-alist' rather than prepending it, its autoload will have + ;; priority over this one. + (add-to-list 'auto-mode-alist '("\\.vue\\'" . web-mode) 'append) + :mode "\\.vue\\'" :config (set-docsets! 'web-mode "HTML" "CSS" "Twig" "WordPress")