1.2.573. Indentation Levels¶
Collect all level of indentations for methods and functions. Inside methods, indentation level raises for structures such as switch, match(), closures, ifthen, and loops. It is recommended to avoid going too high in the levels, as the code becomes less readable.
<?php
function foo() {
$a = 1; // level 1
if ($b == 2) {
$c = 1; // level 2
}
$d = 4; // level 1
}
?>
1.2.573.1. Connex PHP features¶
1.2.573.1.1. Specs¶
Short name |
Dump/IndentationLevels |
Rulesets |
|
Exakat since |
1.9.3 |
PHP Version |
All |
Severity |
Minor |
Time To Fix |
Quick (30 mins) |
Precision |
Very high |
Available in |