render_block_{$this->name} WordPress Filter Hook
This hook is triggered when a block of the specified type is rendered. It allows you to modify the output of the block before it is displayed on the front-end of the site.
apply_filters( "render_block_{$this->name}", string $block_content , array $block , WP_Block $instance ) #
Filters the content of a single block.
Description
The dynamic portion of the hook name, $name
, refers to the block name, e.g. "core/paragraph".
Parameters
- $block_content
(string)The block content about to be appended.
- $block
(array)The full block, including name and attributes.
- $instance
(WP_Block)The block instance.
Source
Changelog
Version | Description |
---|---|
5.9.0 | The $instance parameter was added. |
5.7.0 | Introduced. |