diff --git a/Constants.md b/Constants.md new file mode 100644 index 0000000..6162c43 --- /dev/null +++ b/Constants.md @@ -0,0 +1,21 @@ +As in most languages, constants should be written in UPPERCASE. + +_Notice_: This does not apply to keywords! + +
Example

+ +**Bad** + +```PHP +const pi = 3.14; +``` + +**Good** + +```PHP +const PI = 3.14; +``` + +

+ +_Reference_: [`Generic.NamingConventions.UpperCaseConstantName`](https://github.com/squizlabs/PHP_CodeSniffer/blob/master/src/Standards/Generic/Sniffs/NamingConventions/UpperCaseConstantNameSniff.php) \ No newline at end of file