PHP_CodeSniffer 规范检查修改参考

@高效码农  April 15, 2019

0X01、inline control structures are not allowed

中文释义:不允许使用phpcs内联控制结构,大概意思是if的执行语句不用花括号包起来不是很好,所以将代码改成

if(true){echo 123;}

0X02、phpcs: Line exceeds 120 characters;

中文释义:phpcs:行超过120个字符

修改方法:在超长代码行合适的地方折行;

0X03、Method name "_initialize" should not be prefixed with an underscore to indicate visibility

中文释义:方法名“_initialize”不应以下划线作为前缀

修改方法:暂无



评论已关闭