Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Test:
var foo = { bar : 'barberic'
, baz : 'bazterd'
, duck : 'punch'
};
JSLint Results:
Error:
Problem at line 1 character 19: Bad line breaking before ','.
var foo = { bar : 'barberic'
Problem at line 2 character 19: Bad line breaking before ','.
, baz : 'bazterd'
@tamzinblake

This comment has been minimized.

Copy link

tamzinblake commented Apr 8, 2010

Man, I didn't realize JSLint was broken. Thanks for pointing that out!

@rwaldron

This comment has been minimized.

Copy link
Owner Author

rwaldron commented Apr 8, 2010

Huh? JSLint is not broken - comma-first coding is broken.

@tamzinblake

This comment has been minimized.

Copy link

tamzinblake commented Apr 8, 2010

Woosh

@rwaldron

This comment has been minimized.

Copy link
Owner Author

rwaldron commented Apr 8, 2010

No... I got it. I'm just trying to take a stand against this idiotic practice. (though humor is always appreciated)

@isaacs

This comment has been minimized.

Copy link

isaacs commented Apr 8, 2010

If jslint encourages a coding practice that makes errors harder to spot, then it IS broken.

Thom's original comment was spot on.

@antimatter15

This comment has been minimized.

Copy link

antimatter15 commented Apr 8, 2010

Well, JSLint does spot the missing comma issue, I guess it wants to keep it's job.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.