VIP-Coding-Standards icon indicating copy to clipboard operation
VIP-Coding-Standards copied to clipboard

PHP_CodeSniffer ruleset to enforce WordPress VIP coding standards.

Results 124 VIP-Coding-Standards issues
Sort by recently updated
recently updated
newest added
trafficstars

## Bug Description Adding the `WordPress-VIP-Go` ruleset suppresses many warning from `WordPress-Core`, including `StrictComparisons.LooseComparison`. Sample file (test.php) ```php ``` Output: ``` $ vendor/bin/phpcs test.php W 1 / 1 (100%) ```...

## Describe the solution you'd like When `printf()` is used, we should ensure that the content in the placeholders are correctly escaped. ## What code should be reported as a...

Type: Enhancement

## Bug Description We started flagging for `exclude` since it's an alias of `post__not_in` in #589. Unfortunately, when used outside of a `get_posts()` or WP_Query context, it's a false positive....

With the direction of the "master" term being deprecated in favour of something more ambiguous such as "main" (more context: https://sfconservancy.org/news/2020/jun/23/gitbranchname/), VIPCS should follow suit. This shouldn't be done until...

Type: Maintenance

## What problem would the enhancement address for VIP? When template partials are `require`'d from within a class, then the partial may use `$this->` to insert display a value. At...

Type: Enhancement
Type: False positive

Follow up action after #628 Conversation about this between @GaryJones and @jrfnl from #628: >>> Register with coveralls.io (or another service) and start recording and checking code coverage for builds....

Type: Maintenance

Follow up action after #628 Note: as things stand, testing against PHPCS 4.x requires to run `composer install` using `--prefer-source` as the abstract test case file is no longer included...

Type: Maintenance

Follow up action after #628 Conversation about this between @GaryJones and @jrfnl from #628: > > > (Re-)enable a test run against PHP 8.1/nightly. > > > > Yes, but...

Type: Maintenance

It's almost always meant to be `wp_json_encode`

Type: Enhancement
Status: Has PR

## What problem would the enhancement address for VIP? Some developers are not aware that `esc_url()` supports more than just the `http` and `https` protocols. The default list also includes...

Type: Enhancement