You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.
This is a change in the spec of the rule, or rather a correction of it. The intent of the trailing-comma rule is to make code diffs more precise. Multiline literals should always have trailing commas because the addition of a member should only produce a one-line diff. In your example, a 2-line diff would be produced if you added a field, like this:
Got ya, that makes perfect sense. I thought it was because single comma
objects should never contain more than one item, so you wouldn't need to be
there as you'd never append another item. The diff thing is actually more
useful :) Will update my code, thanks
Since upgrading to 3.5.0, I'm getting errors reported for single lines missing a trailing comma, even though the rules are set up like:
Here is an example line of code which now fails lint under 3.5.0, which used to pass in 3.3.0 with the same rules:
Is this a regression or a change in the spec of this rule?
The text was updated successfully, but these errors were encountered: