Closed angrybacon closed 8 years ago
No, it's excluded from html-mode because html-mode derives from text-mode (which is excluded). You can still turn it on like this:
(add-hook 'html-mode-hook
(lambda ()
(let ((global-aggressive-indent-mode nil))
(aggressive-indent-mode 1))))
However, I suspect you'll find the performance to be suboptimal.
Oh that makes sense.
I have also noticed issues performance-wise with scss-mode. Am I right to assume that contrary to emacs-lisp-mode and js-mode (for instance), scss-mode and html-mode have their whole buffer reindented rather than the current "scope" only? If so, how hard would it be for aggressive-indent to act upon current "scope" only (definition of scope being different for many languages)?
Am I right to assume that contrary to emacs-lisp-mode and js-mode (for instance), scss-mode and html-mode have their whole buffer reindented rather than the current "scope" only?
I've never checked scss-mode. But yes, that's why html-mode is slow.
how hard would it be for aggressive-indent to act upon current "scope" only (definition of scope being different for many languages)?
Moderately hard. PRs welcome. :-)
Is it supposed to work for
html-mode
as well?aggressive-indent-mode
is not active andaggressive-indent-excluded-modes
doesn't containhtml-mode
.