Emacs CSS modes - most feature complete and maintained?
Solution 1:
I'm using the css-mode
that comes with GNU Emacs 24 and it indents fine (the way you want). It does all what you want except validation, and it's part of GNU Emacs so it's maintained. I haven't tried it, but I think css-tidy.el can do validation.
The only customizations I have are
(setq cssm-indent-function #'cssm-c-style-indenter)
(setq cssm-indent-level 2)
but I think those are remnants of some former css mode since neither is defined anywhere. What Emacs are you using and what command is being used to indent (C-h k TAB
)?
Solution 2:
if you are doing inline where you have both html and css code look into nxhtml mode, its one mode that will have the proper syntax editing and highlighting for both css and html.