Fix whitespace-tabs-only-mode warning

This commit is contained in:
Tom Willemse 2018-07-09 19:30:56 -07:00
parent 3bd8d43a47
commit da51208152
2 changed files with 3 additions and 6 deletions

View file

@ -26,11 +26,6 @@
(require 'js2-mode) (require 'js2-mode)
(defun oni-js2-init--js2-whitespace-mode ()
"Enable whitespace mode with only tabs showing."
(setq-local whitespace-style '(face tabs))
(whitespace-mode))
(setq js2-strict-trailing-comma-warning nil) (setq js2-strict-trailing-comma-warning nil)
(setq js2-basic-offset 2) (setq js2-basic-offset 2)
@ -42,7 +37,7 @@
(add-hook 'js2-mode-hook 'tern-mode) (add-hook 'js2-mode-hook 'tern-mode)
(add-hook 'js2-mode-hook 'js2-refactor-mode) (add-hook 'js2-mode-hook 'js2-refactor-mode)
(add-hook 'js2-mode-hook 'fic-mode) (add-hook 'js2-mode-hook 'fic-mode)
(add-hook 'js2-mode-hook 'oni-js2-init--js2-whitespace-mode) (add-hook 'js2-mode-hook 'whitespace-only-tabs-mode)
(provide 'oni-js2-init) (provide 'oni-js2-init)
;;; oni-js2-init.el ends here ;;; oni-js2-init.el ends here

View file

@ -24,6 +24,8 @@
;;; Code: ;;; Code:
(require 'whitespace)
;;;###autoload ;;;###autoload
(defun init-whitespace-only-tabs-mode () (defun init-whitespace-only-tabs-mode ()
"Enable whitespace mode with only tabs showing." "Enable whitespace mode with only tabs showing."