Creating Custom Gutenberg Blocks — a practical guide to create Gutenberg block with clear examples you can reuse in real projects.
WordPress Plugin Development Series (41/95). Prefer one article? Read the complete WordPress plugin development tutorial.
Short description
Start with a simple static block, then add attributes and controls.
Register block
add_action('init', function () {
register_block_type(__DIR__ . '/blocks/notice');
});