excerpt_allowed_wrapper_blocks
Filter HookDescription
Filters the list of blocks that can be used as wrapper blocks, allowing excerpts to be generated from the `innerBlocks` of these wrappers.Hook Information
| File Location | 
                                wp-includes/blocks.php
                                
                                    View on GitHub
                                
                             | 
                        
| Hook Type | Filter | 
| Line Number | 2143 | 
                        
Hook Parameters
| Type | Name | Description | 
|---|---|---|
                                    string[]
                                 | 
                                
                                    $allowed_wrapper_blocks
                                 | 
                                The list of names of allowed wrapper blocks. | 
Usage Examples
                        Basic Usage
                    
                    <?php
// Hook into excerpt_allowed_wrapper_blocks
add_filter('excerpt_allowed_wrapper_blocks', 'my_custom_filter', 10, 1);
function my_custom_filter($allowed_wrapper_blocks) {
    // Your custom filtering logic here
    return $allowed_wrapper_blocks;
}
                        
                    Source Code Context
                        wp-includes/blocks.php:2143
                        - How this hook is used in WordPress core
                    
                    <?php
2138  	 *
2139  	 * @since 5.8.0
2140  	 *
2141  	 * @param string[] $allowed_wrapper_blocks The list of names of allowed wrapper blocks.
2142  	 */
2143  	$allowed_wrapper_blocks = apply_filters( 'excerpt_allowed_wrapper_blocks', $allowed_wrapper_blocks );
2144  
2145  	$allowed_blocks = array_merge( $allowed_inner_blocks, $allowed_wrapper_blocks );
2146  
2147  	/**
2148  	 * Filters the list of blocks that can contribute to the excerpt.
                    PHP Documentation
<?php
/**
	 * Filters the list of blocks that can be used as wrapper blocks, allowing
	 * excerpts to be generated from the `innerBlocks` of these wrappers.
	 *
	 * @since 5.8.0
	 *
	 * @param string[] $allowed_wrapper_blocks The list of names of allowed wrapper blocks.
	 */
                
            
                        Quick Info
                    
                    - Hook Type: Filter
 - Parameters: 1
 - File: wp-includes/blocks.php
 
                        Related Hooks
                    
                    Related hooks will be displayed here in future updates.