Docs: Add and correct examples of common names for various dynamic hooks.

See #53581


git-svn-id: https://develop.svn.wordpress.org/trunk@51327 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
johnbillion
2021-07-03 21:41:02 +00:00
parent 35cf314f9a
commit 5383af8483
10 changed files with 71 additions and 6 deletions
@@ -1024,6 +1024,12 @@ class WP_REST_Posts_Controller extends WP_REST_Controller {
*
* They dynamic portion of the hook name, `$this->post_type`, refers to the post type slug.
*
* Possible hook names include:
*
* - `rest_delete_post`
* - `rest_delete_page`
* - `rest_delete_attachment`
*
* @since 4.7.0
*
* @param WP_Post $post The deleted or trashed post.
@@ -2534,6 +2540,12 @@ class WP_REST_Posts_Controller extends WP_REST_Controller {
* The dynamic portion of the filter, `$this->post_type`, refers to the
* post type slug for the controller.
*
* Possible hook names include:
*
* - `rest_post_item_schema`
* - `rest_page_item_schema`
* - `rest_attachment_item_schema`
*
* @since 5.4.0
*
* @param array $schema Item schema data.