FanCoolo ships a wp fancoolo command, so you can manage blocks, symbols and SCSS partials from the terminal, in scripts or in deployment pipelines. Most commands accept --format=json.
Read
| Command |
What it does |
wp fancoolo list-blocks [--category=<slug>] [--fields=<fields>] |
List blocks |
wp fancoolo get-block <slug> |
Full details of one block |
wp fancoolo list-symbols [--fields=metadata|full] |
List symbols (full includes the PHP) |
wp fancoolo get-symbol <slug> |
One symbol |
wp fancoolo list-scss-partials [--global-only] [--fields=…] |
List SCSS partials |
wp fancoolo get-scss-partial <slug> |
One SCSS partial |
wp fancoolo list-styles |
Block styles |
wp fancoolo list-categories |
Block categories |
wp fancoolo get-design-tokens |
Design tokens from theme.json |
wp fancoolo get-tailwind-config |
Winden's Tailwind theme tokens and classes, if Winden is active |
Create and update
| Command |
What it does |
wp fancoolo create-block "<title>" [--category=<slug>] |
New block |
wp fancoolo create-symbol "<title>" |
New symbol |
wp fancoolo create-scss-partial "<title>" [--global] |
New SCSS partial |
wp fancoolo update-block <slug> [--php-file=<path>] [--scss-file=<path>] [--editor-scss-file=<path>] [--js-file=<path>] [--attributes=<json>] |
Replace a block's code or settings from files |
wp fancoolo update-symbol <slug> --php-file=<path> |
Replace a symbol's PHP |
wp fancoolo update-scss-partial <slug> [--scss-file=<path>] [--global=<true|false>] |
Replace a partial's SCSS or change its global flag |
wp fancoolo delete <slug> [--type=blocks|symbols|scss-partials] [--yes] |
Delete an item |
Files
| Command |
What it does |
wp fancoolo regenerate <slug> |
Generate the files of one item again |
wp fancoolo regenerate-all |
Generate the files of all blocks, symbols and styles again |
Checks
| Command |
What it does |
wp fancoolo validate-security <type> <slug> |
Security scan of a block, symbol or partial (see Code Checks) |
Example: update a block from your editor of choice
wp fancoolo update-block hero --php-file=./hero/render.php --scss-file=./hero/style.scss
wp fancoolo regenerate hero