Loading ...
Sorry, an error occurred while loading the content.

Re: JSLint: Unexpected Space Errors Question

Expand Messages
  • Douglas Crockford
    ... I never imagined that someone would insert a line break before a comma. But I agree that Tolerate sloppy should allow it. It does now.
    Message 1 of 2 , Apr 25, 2009
    • 0 Attachment
      --- In jslint_com@yahoogroups.com, "speedomodel@..." <speedomodel@...> wrote:
      >
      > JSLint produces "Unexpected space" errors for the following:
      >
      > var myArray = [ 1
      > , 2
      > , 3
      > ];
      >
      > Shouldn't having "Tolerate sloppy line breaking" on allow
      > for this? Maybe it's poor style on my part, but I typically
      > code long lists with a comma on the next line for
      > readability. Thanks.

      I never imagined that someone would insert a line break before a comma. But I agree that "Tolerate sloppy" should allow it. It does now.
    Your message has been successfully submitted and would be delivered to recipients shortly.