| name | block-scaffolds |
| description | Copy-paste scaffolds for Oh My Brand! blocks. Templates for block.json, render.php, helpers.php, view.ts, style.css, and tests. Use when creating new blocks. |
| metadata | {"author":"Wesley Smits","version":"1.0.0"} |
Block Scaffolds
Ready-to-use templates for creating new blocks in the Oh My Brand! FSE theme.
When to Use
- Creating a new native WordPress block
- Creating a new ACF block
- Starting test files for blocks
- Quick copy-paste for block files
Placeholders
Replace these placeholders in all templates:
| Placeholder | Replace With | Example |
|---|
BLOCK_NAME | kebab-case name | gallery, hero-section |
BLOCK_TITLE | Human-readable title | Gallery Carousel |
BLOCK_CLASS | PascalCase class | GalleryCarousel |
BLOCK_DESCRIPTION | Short description | Image gallery with carousel |
CATEGORY | Block category | media, text, design |
ICON | Dashicon name | format-gallery, admin-home |
FIELD_NAME | ACF field name | gallery_images |
Native Block Scaffolds
For blocks built with @wordpress/scripts in src/blocks/:
ACF Block Scaffolds
For ACF PRO blocks in blocks/acf-{name}/:
Test Scaffolds
Quick Start
Native Block
mkdir -p src/blocks/my-block
ACF Block
mkdir -p blocks/acf-my-block
Related Skills