dotfiles/emacs/.emacs.d/config/init-web.el

25 lines
709 B
EmacsLisp

;; -*- lexical-binding: t; -*-
(use-package web-mode
:mode (("\\.phtml\\'" . web-mode)
("\\.tpl\\.php\\'" . web-mode)
("\\.[agj]sp\\'" . web-mode)
("\\.as[cp]x\\'" . web-mode)
("\\.erb\\'" . web-mode)
("\\.mustache\\'" . web-mode)
("\\.djhtml\\'" . web-mode)
("\\.hbs\\'" . web-mode)
("\\.html?\\'" . web-mode)
("\\.mako\\'" . web-mode)
("\\.jinja2\\'" . web-mode))
:config
(setq web-mode-engines-alist
'(("django" . "\\.jinja2\\'")))
:custom
(web-mode-enable-auto-pairing nil)
(web-mode-markup-indent-offset 2)
(web-mode-code-indent-offset 2)
(web-mode-script-padding 2))
(provide 'init-web)