Skip to content

Allow extra param docs for functions#5

Merged
mikeybinns merged 1 commit intomainfrom
feature/allow-extra-param-docs-for-functions
Jul 2, 2025
Merged

Allow extra param docs for functions#5
mikeybinns merged 1 commit intomainfrom
feature/allow-extra-param-docs-for-functions

Conversation

@mikeybinns
Copy link
Copy Markdown
Member

WordPress contains a lot of actions and filters which require having a function with parameters defined by WordPress. Sometimes we don't need to use all the parameters so we can leave them off the function, but it's easier to document all the parameters at once.

Allowing extra param docs allows us to include the documentation for unused parameters for later use, instead of having to add the variable and also document it on use.

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Jul 2, 2025

🦋 Changeset detected

Latest commit: d898a88

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
php-coding-standards Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@mikeybinns mikeybinns requested a review from steve-brett July 2, 2025 11:16
Copy link
Copy Markdown
Contributor

@steve-brett steve-brett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, I've been thinking about this too and this is a neat solution.

@mikeybinns mikeybinns merged commit 1fab21b into main Jul 2, 2025
@mikeybinns mikeybinns deleted the feature/allow-extra-param-docs-for-functions branch July 2, 2025 13:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants