Skip to content
Get Bricks

Filter: bricks/builder/dynamic_wrapper

Filters the dynamic wrappers available in the Bricks builder. Dynamic wrappers are used to inject content before or after specific hooks in the builder canvas (e.g., WooCommerce hooks).

  • $dynamic_wrapper (array): Array of dynamic wrappers.
add_filter( 'bricks/builder/dynamic_wrapper', function( $dynamic_wrapper ) {
// Add a custom dynamic wrapper
$dynamic_wrapper[] = [
'name' => 'my_custom_wrapper',
'title' => esc_html__( 'My Custom Wrapper', 'my-plugin' ),
'hooks' => [
'before' => 'my_custom_action_before',
'after' => 'my_custom_action_after',
],
];
return $dynamic_wrapper;
} );