/flavian:fse-block-theme-developmentfrom Flavian
Builds WordPress FSE block themes: theme.json design tokens, HTML templates, template parts, and block patterns. Covers structure and migration from classic themes.
Ships in Flavian. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
FSE (Full Site Editing) block themes require a systematic, design-system-first approach. The theme.json file defines the design system (colors, typography, spacing), templates use those tokens, and patterns compose blocks into reusable UI components.
Core Principle: theme.json FIRST → templates SECOND → patterns THIRD. Never skip theme.json setup or hardcode values.
Use this skill when:
Symptoms that trigger this skill:
When NOT to use:
This project uses ROOT-LEVEL folders during development:
project-root/
└── themes/theme-name/ ← Create themes HERE (NOT wp-content/themes/)
NEVER create files in wp-content/themes/ during development. All theme development happens in the root-level themes/ directory. Testing environments copy files to WordPress wp-content/ for deployment.
Minimal FSE theme requires:
themes/theme-name/ ← ROOT-LEVEL (not wp-content/themes/)
├── style.css # Theme header (REQUIRED)
├── theme.json # Design system (REQUIRED)
├── templates/
│ └── index.html # Fallback template (REQUIRED)
└── parts/ # Optional but recommended
├── header.html
└── footer.html
Complete FSE theme structure:
themes/theme-name/ ← ROOT-LEVEL (not wp-content/themes/)
├── style.css
├── theme.json
├── functions.php # Optional: custom functionality
├── templates/
│ ├── index.html # Required fallback
│ ├── front-page.html
│ ├── home.html # Blog index
│ ├── single.html # Single post
│ ├── page.html # Single page
│ ├── archive.html # Archive pages
│ ├── search.html
│ └── 404.html
├── parts/
│ ├── header.html
│ ├── footer.html
│ └── sidebar.html
├── patterns/ # Custom block patterns
│ ├── hero.php
│ ├── call-to-action.php
│ └── testimonial.php
└── assets/ # Theme assets
├── css/
├── js/
└── images/
| Step | Action | Purpose |
|---|---|---|
| 1 | Create style.css header | Theme metadata |
| 2 | Create theme.json schema | Design system foundation |
| 3 | Define color palette | Brand colors as tokens |
| 4 | Define typography | Font families, sizes, line heights |
| 5 | Define spacing scale | Consistent padding/margin values |
| 6 | Configure layout settings | Content width, wide width |
| 7 | Set block supports | Enable/disable block features |
| 8 | Create templates | Use theme.json tokens |
| 9 | Create template parts | Reusable header/footer |
| 10 | Build patterns | Compose blocks into UI |
Templates follow WordPress template hierarchy, with .html extension:
Front page: front-page.html → home.html → index.html
Blog index: home.html → index.html
Single post: single-{post-type}-{slug}.html → single-{post-type}.html → single.html → singular.html → index.html
Page: page-{slug}.html → page-{id}.html → page.html → singular.html → index.html
Archive: archive-{post-type}.html → archive.html → index.html
Search: search.html → index.html
404: 404.html → index.html
Minimal theme header:
/*
Theme Name: My Block Theme
Theme URI: https://example.com/my-block-theme
Author: Your Name
Author URI: https://example.com
Description: A custom FSE block theme
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: my-block-theme
Tags: block-themes, full-site-editing, accessibility-ready
*/
Schema version 3 (WordPress 6.6+):
{
"$schema": "https://schemas.wp.org/trunk/theme.json",
"version": 3,
"settings": {
"color": {
"palette": [
{
"slug": "primary",
"color": "#0073aa",
"name": "Primary"
},
{
"slug": "secondary",
"color": "#23282d",
"name": "Secondary"
},
{
"slug": "foreground",
"color": "#000000",
"name": "Foreground"
},
{
"slug": "background",
"color": "#ffffff",
"name": "Background"
}
],
"defaultPalette": false,
"defaultGradients": false
},
"typography": {
"fontFamilies": [
{
"fontFamily": "-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif",
"slug": "system",
"name": "System"
}
],
"fontSizes": [
{
"slug": "small",
"size": "0.875rem",
"name": "Small"
},
{
"slug": "medium",
"size": "1rem",
"name": "Medium"
},
{
"slug": "large",
"size": "1.5rem",
"name": "Large"
},
{
"slug": "x-large",
"size": "2rem",
"name": "Extra Large"
}
],
"defaultFontSizes": false
},
"spacing": {
"spacingScale": {
"steps": 0
},
"spacingSizes": [
{
"slug": "small",
"size": "1rem",
"name": "Small"
},
{
"slug": "medium",
"size": "2rem",
"name": "Medium"
},
{
"slug": "large",
"size": "4rem",
"name": "Large"
}
],
"padding": true,
"margin": true
},
"layout": {
"contentSize": "650px",
"wideSize": "1200px"
}
},
"styles": {
"color": {
"background": "var(--wp--preset--color--background)",
"text": "var(--wp--preset--color--foreground)"
},
"typography": {
"fontFamily": "var(--wp--preset--font-family--system)",
"fontSize": "var(--wp--preset--font-size--medium)",
"lineHeight": "1.6"
},
"spacing": {
"padding": {
"top": "0px",
"right": "var(--wp--preset--spacing--medium)",
"bottom": "0px",
"left": "var(--wp--preset--spacing--medium)"
}
}
}
}
Minimal fallback template:
<!-- wp:template-part {"slug":"header","tagName":"header"} /-->
<!-- wp:group {"tagName":"main","layout":{"type":"constrained"}} -->
<main class="wp-block-group">
<!-- wp:query {"queryId":0,"query":{"perPage":10,"pages":0,"offset":0,"postType":"post","order":"desc","orderBy":"date","author":"","search":"","exclude":[],"sticky":"","inherit":true}} -->
<div class="wp-block-query">
<!-- wp:post-template -->
<!-- wp:post-title {"isLink":true} /-->
<!-- wp:post-date /-->
<!-- wp:post-excerpt /-->
<!-- /wp:post-template -->
<!-- wp:query-pagination -->
<!-- wp:query-pagination-previous /-->
<!-- wp:query-pagination-numbers /-->
<!-- wp:query-pagination-next /-->
<!-- /wp:query-pagination -->
<!-- wp:query-no-results -->
<!-- wp:paragraph -->
<p>No posts found.</p>
<!-- /wp:paragraph -->
<!-- /wp:query-no-results -->
</div>
<!-- /wp:query -->
</main>
<!-- /wp:group -->
<!-- wp:template-part {"slug":"footer","tagName":"footer"} /-->
CORRECT - Using CSS variables:
<!-- wp:group {"style":{"color":{"background":"var(--wp--preset--color--primary)"},"spacing":{"padding":{"top":"var(--wp--preset--spacing--large)","bottom":"var(--wp--preset--spacing--large)"}}}} -->
<div class="wp-block-group has-background" style="background-color:var(--wp--preset--color--primary);padding-top:var(--wp--preset--spacing--large);padding-bottom:var(--wp--preset--spacing--large)">
<!-- Block content -->
</div>
<!-- /wp:group -->
INCORRECT - Hardcoding values:
<!-- NEVER DO THIS -->
<div style="background-color:#0073aa;padding-top:4rem;">
WRONG:
"The client needs the theme today, let's skip theme.json for now and just hardcode the styles."
WHY THIS FAILS:
CORRECT: Start with minimal theme.json (10 minutes), even if you only define primary color and base font. You can always expand it later.
WRONG:
<!-- wp:group {"style":{"color":{"background":"#0073aa"}}} -->
WHY THIS FAILS:
CORRECT:
<!-- wp:group {"style":{"color":{"background":"var(--wp--preset--color--primary)"}}} -->
WRONG:
Creating only index.html and expecting different layouts for posts vs pages.
WHY THIS FAILS:
CORRECT: Create specific templates for different contexts:
single.html for blog postspage.html for static pagesarchive.html for category/tag archives404.html for not found pagesWRONG:
Creating front-page.html and single.html but no index.html.
WHY THIS FAILS:
CORRECT:
Always create templates/index.html first, even if you plan to override it with specific templates.
WRONG: Adding CSS to style.css for block spacing, colors, typography.
WHY THIS FAILS:
CORRECT: Define all design tokens in theme.json, let WordPress generate CSS automatically.
WRONG: Testing theme only with default paragraph and heading blocks.
WHY THIS FAILS:
CORRECT: Test with diverse blocks:
WRONG: "We'll add accessibility later after launch."
WHY THIS FAILS:
CORRECT: During development:
These thoughts indicate you're about to violate FSE best practices:
| Rationalization | Reality | Correct Action |
|---|---|---|
| "Let's skip theme.json for now" | theme.json is REQUIRED and foundational | Create minimal theme.json (10 min) |
| "We'll just hardcode this color" | Breaks design system, not customizable | Add color to theme.json palette |
| "index.html isn't needed yet" | It's the required fallback template | Create index.html FIRST |
| "Inline styles are faster" | Bypasses WordPress design system | Use theme.json tokens |
| "We don't have time for testing" | Bugs compound and are harder to fix later | Test incrementally as you build |
| "Accessibility can wait" | Must be built in from start | Use semantic HTML, test as you go |
| "Users won't customize this" | Cannot predict future needs | Follow design system principles |
| "This is just a prototype" | Prototypes become production | Build it right from the start |
NEVER skip these requirements, regardless of pressure:
Time pressure is not a valid reason to skip these. Client deadlines are not a valid reason to skip these. "We'll fix it later" is not a valid reason to skip these.
This skill works with:
Complements these skills:
Before considering an FSE theme complete:
Skill Version: 1.0.0 Last Updated: 2026-01-18 Tested Against: WordPress 6.7+ Testing Methodology: RED-GREEN-REFACTOR (TDD for documentation)
What SKILL.md sets; muted values are Claude Code's defaults
16 skills in this plugin
/block-pattern-creationUse when creating WordPress block patterns, registering patterns, organizing pattern categories, or building reusable UI components with blocks. Keywords: block patterns, register_block_pattern, pattern category, InnerBlocks, WordPress patterns, reusable blocks/canva-to-fse-autonomous-workflowUse when converting Canva HTML/CSS exports to WordPress FSE block themes. Orchestrates autonomous workflow from CSS token extraction through template generation. Keywords: Canva to WordPress, FSE conversion, HTML export, CSS design tokens, autonomous template generation/create-blog-articleCreate an SEO-optimized blog article for a Claude Code component with AI-generated cover imagenpx claudepluginhub pmdevsolutions/flavian --plugin flavianOther plugins' skills for the same job