Add PHPStan and PHP Mess Detector for improved code quality

This commit is contained in:
2025-04-21 04:58:51 +01:00
parent aa62142e4c
commit 78bd0708d3
5 changed files with 83 additions and 14 deletions

19
phpstan.neon Normal file
View File

@@ -0,0 +1,19 @@
parameters:
level: 5
paths:
- includes
- admin
- wp-plugin-starter-template.php
excludePaths:
- vendor
- node_modules
- tests
- bin
- build
- dist
ignoreErrors:
- '#Function apply_filters invoked with [0-9]+ parameters, 2 required.#'
- '#Function do_action invoked with [0-9]+ parameters, 1 required.#'
- '#Function add_action invoked with [0-9]+ parameters, 2 required.#'
- '#Function add_filter invoked with [0-9]+ parameters, 2 required.#'
reportUnmatchedIgnoredErrors: false