Home > front end >  What are "MySource" and "Squiz" Coding Standards?
What are "MySource" and "Squiz" Coding Standards?

Time:01-31

After installing Composer in windows 10, the result of phpc -i command is:

"The installed coding standards are MySource, PEAR, PSR1, PSR12, PSR2, Squiz and Zend."

After lots of searches I was unable to find any documentation about MySource coding standard, nor for Squiz coding standard.

So what are these two standards? Are there any link to their documentation to see what sniffs they do?

In fact I need to know are there any extra sniffs which these two standard do in comparison with PSR12? (currently I've set only PSR1,PSR12 in my vscode code sniffer extension settings.)

CodePudding user response:

Squiz Labs is (or was?) the group behind PHP CS. You can see that in the repo URL: https://github.com/squizlabs/PHP_CodeSniffer

From the ruleset definition:

The MySource coding standard builds on the Squiz coding standard. Currently used for MySource Mini development.

CodePudding user response:

The Squiz coding standard has a lot of useful sniffs in there, and they are used by some of the other included standards. The MySource standard is old and not useful, is deprecated, and already removed in the 4.0 branch.

  •  Tags:  
  • Related