r/ProWordPress • • 9d ago

Honest dev feedback wanted: Separating WordPress core structure (parent theme) from visual "Skins" + using strict JSON schemas & phase protocols to keep AI coding agents from breaking architecture

Hi everyone,

I’m a solo designer and developer from Japan running a small studio. \*(Sorry in advance for my English—I’m using AI to help translate!)\*

I’m not here to promote anything or drop commercial links—I genuinely want to share an architecture and AI-assisted workflow I’ve been building for WordPress client work, and get honest feedback from fellow WordPress developers.

\### The Problem I Wanted to Solve
Over the years, I’ve had to rescue a lot of broken WordPress sites where multiple redesigns were stacked on top of each other—ending up with \`!important\` wars, broken skip links/keyboard focus, and layouts that break whenever the theme updates.

At the same time, when I started using AI coding agents (Cursor, Claude Code, Codex, etc.) for client sites, I noticed that without strict boundaries, AI tends to hallucinate custom CSS overrides, blur responsibilities between theme and plugins, or silently break baseline accessibility.

\### The Architecture I Built Around It
To solve both issues at once, I designed a strict separation model:

  1. \*\*Standardized Parent Theme (Core Structure & Baseline QA):\*\*
    \- Handles the shared WordPress foundation, security/update resilience, keyboard navigation/skip links, and structural baselines—so updating the core never breaks client-specific designs.
    \- \*(Note: The parent theme itself is a 100% free GPL classic theme listed on WordPress.org under \`Variable Thema\`.)\*
  2. \*\*Lightweight Child Themes ("Skins"):\*\*
    \- Each client site gets its own isolated Skin responsible \*only\* for visual layout and styling, governed by an explicit Parent-Skin responsibility contract.
  3. \*\*Structured Markdown & JSON Schema Protocols for AI Agents (Not Just Ad-Hoc Prompts):\*\*
    \- Instead of asking an AI to "build or migrate a site" freehand, I built a 20-phase execution protocol and a formal \*\*Phase-00 Diagnosis JSON Schema (\`diagnosis.schema.json\`)\*\*.
    \- Before writing a single line of theme code, the AI and human run a structured Phase-00 diagnosis (for either a greenfield build or legacy theme migration), classify ownership boundaries, and execute step-by-step through isolated build, migration, and QA gates (including No-JS and keyboard accessibility checks, plus a sandbox lab fixture for skin-switching and troubleshooting).

\### What I’d Love Your Honest Take On
As fellow WordPress builders:

  1. Does this strict \*\*"Parent Core + Isolated Visual Skin"\*\* split match how you manage long-term client maintenance, or do you prefer full block themes / FSE / custom starter themes from scratch?
  2. For those using AI coding agents in WordPress workflows: how are you keeping AI from making messy architectural shortcuts? Do structured JSON schemas and phase-by-phase Markdown guardrails resonate with how you work?

Would love to hear how you approach this in your own shops—any critical feedback is super welcome!

0 Upvotes

13 comments sorted by

2

u/creaturefeature16 9d ago

Wat

1

u/Living-Pen-3905 9d ago

Haha fair, my bad—I crammed way too much into one post!

TL;DR: I just got tired of AI coding agents trashing client sites with random `!important` overrides, so I make the AI fill out a strict checklist file before it's allowed to touch any CSS.

Curious how you keep AI from making a mess in WP?

3

u/creaturefeature16 9d ago

I don't let agents write CSS. They're terrible at it. 

1

u/Living-Pen-3905 9d ago

Honestly, that’s probably the smartest move!

I’m leaning closer to that too—keeping CSS layout and design decisions strictly human-owned, and only letting AI handle boilerplate or run QA checks against the schema. Way less headache than cleaning up AI-generated CSS spaghetti!

2

u/tw2113 Developer 9d ago

I don't let agents into my websites.

1

u/ivicad 8d ago

On my client sites, Claude Code makes its changes through WP-CLI on a local copy. I check the result there and move it to the live site myself, if it's ok. Everything goes through builder elements (mostly WPBakery AI), so the client keeps editing them the way they did before.

Each time I correct the agent, the correction goes into the skill it reads before the next site, so I fix the same mistake once, and it learns from its own mistakes along the way.

1

u/creaturefeature16 8d ago

WPBakery

Your poor, poor clients...

0

u/automayweather 9d ago

The parent and skin split is the sound half, it is disciplined child theming with twenty years of proof. The JSON protocol layer worries me more: a contract that silently drifts from the real template hierarchy is worse than none, so recheck it against hooks and templates on every build.

0

u/Living-Pen-3905 9d ago

That’s such a sharp point—and honestly the exact failure mode I’m most paranoid about!

A JSON contract that silently drifts away from the actual WordPress template hierarchy and hooks gives a false sense of security, which is worse than having no contract at all.

To prevent that drift, the JSON schema is only treated as an upfront plan—every build and parent update still has to pass automated/rendered structural checks against the actual active templates, hooks, and DOM output before anything ships.

Really appreciate you calling that out—keeping the spec locked to reality is half the battle!

-1

u/metallzoa 9d ago

Install Bricks and disable gutenberg, do you really need to over-complicate it this much