Of course, an IDE as powerful as NetBeans is not insignificant, but since I just print the code, here's how it formats it:
$(document).ready(function() {
if (someVar > 2)
{
complain('that is not how you indent braces');
}
else if (someVar == -1)
complain('this is not right either!');
else
{
complain('but it did auto outdent the else which is smart');
complain('smart indeed');
}
});
How can I fix this, so it formats as such:
$(document).ready(function() {
if (someVar > 2)
{
}
else if (someVar == -1)
else
{
}
});
source
share