A simple subset of zencoding-mode for Emacs. It completes these types: div -->
input --> .article --> #logo --> ul.items -->
tag inside some prose, and it garbled the
entire sentence. That doesn't happen here, since this subset does not
look past whitespace.
It also will not try to expand anything that is not a known html-tag,
reducing the number of errors when I just want to indent the line.
Yes, I have it on TAB.
## Setup
You can bind `simplezen-expand` to any button of your choosing.
(require 'simplezen)
(define-key html-mode-map (kbd "C-c C-z") 'simplezen-expand)
If you want it bound to `tab` you can do this:
(define-key html-mode-map (kbd "TAB") 'simplezen-expand-or-indent-for-tab)
Then it will still indent the line, except in cases where you're
looking back at a valid simplezen-expression (see above).
To get it working with yasnippet aswell, I did this:
(defun --setup-simplezen ()
(set (make-local-variable 'yas/fallback-behavior)
'(apply simplezen-expand-or-indent-for-tab)))
(add-hook 'sgml-mode-hook '--setup-simplezen)
Which will give yasnippet first priority, then simplezen gets it
chance, and if neither of those did anything it will indent the line.