humanmade / humanmade/coding-standards

Sniff to enforce presence of docblock above actions and filters

Open
#141 0 comments 1 reaction 0 assignees View on GitHub
enhancement phpcs
Dominant language
PHP
Stars
160
Forks
17
PR merge metrics
No merged PRs in 30d

Description

A docblock should be present above all calls to the following:

* `do_action()`
* `apply_filters()`
* `do_action_ref_array()`
* `apply_filters_ref_array()`
* `do_action_deprecated()`
* `apply_filters_deprecated()`

A sniff which enforces this would be handy. Validating the docblock should probably be done separately as it's quite complex.

WPCS issue: https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards/issues/424

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.