📣 You can now sponsor Slevomat Coding Standard development
🆕 New sniffs
RequireSingleLineConditionSniff
: Enforces conditions ofif
,elseif
,while
anddo-while
to be on a single lineRequireMultiLineConditionSniff
: Enforces conditions ofif
,elseif
,while
anddo-while
with one or more boolean operators to be splitted to more lines so each condition part is on its own lineRequireSingleLineCallSniff
: Enforces function call to be on a single lineRequireMultiLineCallSniff
: Enforces function call to be splitted to more lines so each parameter is on its own lineDeprecatedAnnotationDeclarationSniff
: Reports@deprecated
annotations without description (thanks to @gmponos)SuperfluousErrorNamingSniff
: Reports use of superfluous suffixError
for errors (thanks to @gmponos)
🔧 Improvements
- All sniffs should work on PHP 8 if you don't use new syntax - new syntax has to be supported by PHPCS first
- Support for
class-string
type hint DuplicateSpacesSniff
: New optionignoreSpacesInParameters
InlineDocCommentDeclarationSniff
: New optionallowAboveNonAssignment
ReferenceUsedNamesOnlySniff
: Less colisions withAlphabeticallySortedUsesSniff
🐛 Fixes
LanguageConstructWithParenthesesSniff
: Some errors were not reported
⚠️Deprecated
UnusedPrivateElementsSniff
: Mark as deprecated