rspec/rules/S1066/description.adoc
2023-10-16 09:46:41 +00:00

4 lines
324 B
Plaintext

Nested code - blocks of code inside blocks of code - is eventually necessary, but increases complexity. This is why keeping the code as flat as possible, by avoiding unnecessary nesting, is considered a good practice.
Merging `if` statements when possible will decrease the nesting of the code and improve its readability.