1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-02-02 20:16:25 +00:00

2 Commits

Author SHA1 Message Date
Dmitry Gutov
939fef2978 Mention test/indent/js.js, and restore one lost piece of it
* test/indent/js.js: New file.
2013-12-08 18:11:08 +02:00
Dmitry Gutov
47e59c666a Port indentation code from js2-mode to js-mode
* lisp/progmodes/js.el (js-auto-indent-flag): Remove, was unused.
(js-switch-indent-offset): New option.
(js--proper-indentation): Use it.  And handle the case when
"default" is actually a key in an object literal.
(js--same-line): New function.
(js--multi-line-declaration-indentation): Use it.
(js--indent-in-array-comp, js--array-comp-indentation): New
functions.
(js--proper-indentation): Use them, to handle array comprehension
continuations.
2013-12-08 18:08:45 +02:00