# b-blocks/2.1.8/build/hero-section/render.php

bBlocks – Essential Gutenberg Blocks &amp; Patterns Collection, version 2.1.8. 23 lines.

- Page: https://pluginprobe.com/plugins/b-blocks/2.1.8/code/build/hero-section/render.php
- Raw: https://pluginprobe.com/plugins/b-blocks/2.1.8/raw/build/hero-section/render.php
- Modified: 2026-09-27T04:52:46+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/b-blocks/2.1.8/code/build/hero-section/render.php#L10-L20`.

```php
<?php
/**
 * Hero Section block server-side render.
 *
 * Following the bplugins convention (see image-hotspot / article-card), the
 * server only emits an empty wrapper carrying the block attributes as JSON.
 * React hydrates the hero on the frontend via view.js.
 *
 * @package bBlocks
 *
 * @var array    $attributes Block attributes.
 * @var WP_Block $block      Block instance.
 */

$id = wp_unique_id( 'hero-section-' );
?>
<div
	<?php // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- get_block_wrapper_attributes() is properly escaped ?>
	<?php echo get_block_wrapper_attributes(); ?>
	id='<?php echo esc_attr( $id ); ?>'
	data-attributes='<?php echo esc_attr( wp_json_encode( $attributes ) ); ?>'
></div>

```
