-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enforce consistent indentation for arrays #28
Conversation
I support this, but only from an aesthetic standpoint. I'm not aware of any practical benefits of one option or the other. |
I think this is a purely aesthetic cop, so I don't know that there are any practical benefits to either. Unless you consider readability to be a practical benefit, in which case my opinion is that the "consistent" style is easier to read. |
Does this consider the following valid/in adherence with the style: array =
[
:value
]
and_in_a_method_call(
[
:value
]
) |
Oh interesting, yeah @kevin-j-m you're right - that syntax satisfies either rule. So I guess the question is how do we feel about option 1 vs option 2? With # option 1
method_call([
:foo,
])
# option 2
method_call(
[
:foo,
],
) |
So, for me, I'd consider it incredibly unlikely to in-line an array in a method call anyway, so I'm not sure I really care about the method formatting that much, but I would also prefer Is there a scenario where this is actually common that I'm neglecting to consider? |
I can't think of any, for whatever that's worth |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like this needs a rebase because we spaced this. The style is solid though 👍
documentation