jstoolnpp
jstoolnpp copied to clipboard
Incorrect indents?
Hi! It seems there is a problem with the indentation 1.
var a = 0,
b = 1;
should be
var a = 0,
b = 1;
a += v1 + v2 +... +
v7 + v8
should be
a += v1 + v2 +... +
v7 + v8
$Window.off('click')
? true
: false;
should be
$Window.off('click')
? true
: false;
$Pic.removeAttr('src')
.removeProp('title')
.hide();
should be
$Pic.removeAttr('src')
.removeProp('title')
.hide();
switch (foo) {
case 1:
bar = 1;
break;
default:
bar = 2;
}
should be
switch (foo) {
case 1:
bar = 1;
break;
default:
bar = 2;
}
I'll see what i can do to enhance format.
I forgot about another case:
return (typeof value === "number")
? Math.floor(value)
: (typeof value === "string")
? value.charCodeAt(0)
: default_value;
should be
return (typeof value === "number")
? Math.floor(value)
: (typeof value === "string")
? value.charCodeAt(0)
: default_value;
Thanks!
@underr-ua The title of your issue should be "Incorrect indents?". Perhaps you should correct it.
@sunjw - just downloaded the tool, works great but I can second the indentation issues. "Dependent" code (like continued lines) needs to be indented, this is quite important for readability.