I get the following:
var
a = 5,
b = 6,
c = foo();
/* code continues */
I want:
var
a = 5,
b = 6,
c = foo();
/* OUTDENT, code continues */
I know as per How to get js-mode to properly indent continued (compound?) var declarations? there is some hack for js2-mode which gets it done. I would like to know how to do it with javascript-mode (the built-in one, into emacs 24). "var" should indent one level until the first semicolon after var. Comma-first-style should not alter that.
Ideally, I could have it in my init.el, which I could then sync to every computer I am working on. Is that possible? How do I do it?