Emacs: delay loading skewer until needed
Alan Pearce alan@alanpearce.co.uk
Sat, 08 Jun 2013 14:04:41 +0100
1 files changed, 6 insertions(+), 3 deletions(-)
jump to
M emacs/init.el → emacs/init.el
@@ -1041,7 +1041,12 @@ (interactive) (comint-send-string (inferior-moz-process) "BrowserReload();")))) (use-package skewer-mode - :ensure t) + :ensure t + :defer t + :init (progn + (add-hook 'js2-mode-hook #'skewer-mode) + (add-hook 'html-mode-hook #'skewer-html-mode) + (add-hook 'css-mode-hook #'skewer-css-mode))) (use-package js2-mode :ensure t @@ -1050,8 +1055,6 @@ :config (progn (defun ap/javascript-setup () (if (featurep 'moz) (moz-minor-mode)) - (if (featurep 'skewer-mode) - (skewer-mode +1)) (autopair-mode -1) (auto-indent-mode -1)) (add-hook 'js2-mode-hook #'ap/javascript-setup)