Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork3.4k
Open
Labels
Description
I encountered a situation where ado...end
block syntax is used as a work-around to avoid line limits.
Example:
# frozen_string_literal: trueif [].any? do |variable| # do somethingend trueend
Indenting the block by one level helps identify the end of the conditional easily but still does not feel naturalat least to me. This results in aLayout/BlockAlignment
offense.
# frozen_string_literal: trueif [].any? do |variable| # do something end trueend
Could we enforce thatdo..end
blocks are not used in conditionals or have a style-preference if we support it?