wp scaffold block <slug>
Generates PHP, JS and CSS code for registering a Gutenberg block for a plugin or theme
Arguments
Name | Description |
---|
slug | The internal name of the block |
Options
Name | Description |
---|
--title <title> | The display title for your block |
--dashicon <dashicon> | The dashicon to make it easier to identify your block |
--category <category> | The category name to help users browse and discover your block |
--theme | Create files in the active theme directory. Specify a theme with --theme=<theme> to have the file placed in that theme |
--plugin <plugin> | Create files in the given plugin’s directory |
--force | Overwrite files that already exist |