Skip to content

Status: Draft structure — validated with sdc.com. Production use begins after workflow refinement.

This document is the single source of truth for the Content-First Web Dev workflow used to build sdc.com and ts.com. It covers all 6 steps plus the monorepo relationship.


Web development typically starts with UI (design system, components, Tailwind) and treats content as a fill-in-later detail. This workflow inverts that: content and UX come first, formatting and code come last.

This matters because:

  • The 20% of content that drives 80% of outcomes is clearly identified before any code is written
  • AI tools are far more effective working on pure Markdown than on HTML/CSS/JSX
  • Role separation is enforced structurally — CMO doesn’t need to touch code; dev doesn’t need to manage content strategy

This workflow is a companion to the monorepo — not a replacement.

LayerToolResponsibility
Content strategy & draftingObsidian vaults (content-high-level, content-all)What to say and to whom
Schema enforcementKeystatic (in monorepo)Structured MDX, collection validation
UI & functionalityAstro + Tailwind + SvelteKit (monorepo)How it looks and works
Testing groundsites/Template/ in monorepoAll components validated here before production use
DeploymentMonorepo CI/CD pipelineBuild, test, ship

The Template site (sites/Template/) is the development reference. All new components, layouts, and functionality are built and tested there first. When content is ready to render (Step 5), the monorepo already has production-ready components waiting.


StepNameToolInputOutputTransition Criterion
0Business FoundationKB / ObsidianICP, USP, mission, brand voiceStrategy is stable
1+2Core Content + UXcontent-high-level vaultStep 0 outputsCore pages + wikilink UX prototypeAll core pages status: review
0.5AI Content Expansion/content-expand skillcontent-high-level vaultTighter copy, stronger CTAsCore pages status: approved
3All Content + Schemacontent-all vault + KeystaticApproved core pagesAll pages in Astro collections, schemas validAll pages in Keystatic; pnpm typecheck passes
4LocalizationGitHub Actions + Claude APIApproved MDX/[locale]/ MDX filesOnly if/when needed
5UIAstro + Tailwind (monorepo)Keystatic MDXRendered, styled siteVisual + responsive QA passes
6ReviewChecklist belowLive siteSign-offAll checklist items green

Tool: KB Obsidian vault (KB/Business/02_Strategy/) Who: Founder / CMO

Define and stabilize:

  • Ideal Client Profile (ICP)
  • Unique Selling Proposition (USP) + brand voice
  • Mission statement
  • Core business model (what, why, for whom)
  • Key Success Factors, SWOT

Transition: Strategy docs are stable. Extracted references placed in _00_strategy/ in the content vaults (read-only during content work).


Steps 1 + 2 — Core Content + UX Prototype

Section titled “Steps 1 + 2 — Core Content + UX Prototype”

Tool: content-high-level Obsidian vault Location: D:\FSS\Websites\SDC.com\content-high-level\ Who: CMO / founder

Write the 20% of pages that deliver 80% of the value — in pure Markdown, no code, no UI decisions:

  • Homepage
  • Primary audience pages (advisors, investors)
  • About
  • Key educational content (e.g., smart-debt-myths)

Each page uses the standard frontmatter schema (type, audience, phase, status, slug, description, cta_primary).

Use wikilinks ([[page-name]]) to prototype the critical user journeys:

  • Stranger → visitor → interested prospect → client → happy client
  • Nav component links all pages
  • CTAs link to the next logical step

The wikilinks ARE the UX prototype. Click through pages in Obsidian as if you’re a visitor.

Transition: All core pages at status: review. Wikilinks all resolve. CMO satisfied with the narrative flow.


Tool: /content-expand Claude Code skill Who: AI (Claude Code or Gemini CLI)

Run after Steps 1+2, before Keystatic import. AI reads the vault, tightens copy, and verifies CTA alignment.

Invoke:

/content-expand D:\FSS\Websites\SDC.com\content-high-level

What it does:

  1. Reads all pages/ and components/ in the vault
  2. References _00_strategy/ICP.md and USP.md for alignment
  3. For each status: draft or review file: tightens headlines, sharpens body copy, verifies primary CTA
  4. Reports changes per file — asks for confirmation before writing anything

Transition: All core pages at status: approved. Human has confirmed each change.


Tools: content-all Obsidian vault + Keystatic Locations:

  • Vault: D:\FSS\Websites\SDC.com\content-all\
  • Keystatic config: monorepo/sites/sdc.com/keystatic.config.ts Who: Junior team member or AI (CMO does not need to be involved)

Add all remaining pages and components:

  • Blog index, Contact, Pricing, FAQ
  • Footer, social proof, email capture
  • Any locale-specific variants (if known in advance)

Once content is approved in both vaults, import to Keystatic:

  1. Install Keystatic: pnpm add @keystatic/core @keystatic/astro
  2. Add Keystatic integration to astro.config.mjs
  3. Uncomment keystatic.config.ts (currently fully commented — see file)
  4. Run Keystatic locally: pnpm dev
  5. Import/paste MDX content into Keystatic UI
  6. Validate schema: pnpm typecheck

Transition: All pages in Keystatic collections. pnpm typecheck passes with no errors.


Step 4 — Localization (Skeleton — Not Yet Implemented)

Section titled “Step 4 — Localization (Skeleton — Not Yet Implemented)”

Tools: GitHub Actions + Claude API Location: .github/workflows/localize.yml (manual trigger only — disabled) Who: Dev (one-time setup); AI handles translation

Only when a second locale is needed. Current target: English only.

  1. Approved MDX files from Step 3 are the translation source
  2. GitHub Action calls Claude API with the translation prompt template
  3. Translated MDX is written to /[locale]/ routes in the monorepo
  4. No manual side-by-side CMS translation UI needed

Prompt template: D:\FSS\Websites\SDC.com\content-all\_templates\translate-prompt.md

To activate:

  1. Implement sites/sdc.com/scripts/translate.ts (stub in workflow comments)
  2. Add ANTHROPIC_API_KEY secret to GitHub repo settings
  3. Change workflow trigger from workflow_dispatch to desired branch trigger
  4. Remove the ## DISABLED comment in the workflow file

Tools: Astro + Tailwind (monorepo sites/sdc.com/) Who: Dev

At this point, all content is structured MDX in Keystatic. Dev renders it using Astro components that were already tested in sites/Template/.

Process:

  1. Reference sites/Template/ for validated component patterns
  2. Build Astro pages that consume Keystatic content collections
  3. Apply design tokens from @smart-debt/design-tokens workspace package
  4. Mobile-first: build at 390px, scale up

Quality bar:

  • Mobile responsive (390px, 768px, 1280px)
  • Dark mode (if applicable)
  • WCAG AA contrast
  • Lighthouse score ≥ 90

Who: CMO + dev

Content–UI Alignment

  • Every page’s headline matches the intent from content-high-level
  • All CTAs are visible above the fold on mobile
  • No placeholder text remains in production build

SEO / Meta

  • Every page has a unique <title> and <meta description>
  • description frontmatter field is populated for all pages
  • Canonical URLs correct
  • sitemap.xml generated

CTA Coverage

  • Every page has at least one primary CTA
  • Core pages (home, advisors, investors) have a CTA in the hero
  • All CTAs link to valid, live pages

Mobile / Responsive

  • No horizontal scroll on any page at 390px
  • Touch targets ≥ 44x44px
  • Text is readable without zooming (≥ 16px base)

Accessibility

  • WCAG AA color contrast on all text/background combinations
  • All images have descriptive alt text
  • Keyboard navigation works (Tab, Enter, Escape)
  • Screen reader: headings are in logical order (h1 → h2 → h3)

Performance

  • Lighthouse Performance score ≥ 90 (mobile)
  • No render-blocking resources
  • Images are optimized (Astro <Image /> component)

Compliance

  • Footer includes compliance/disclaimer text
  • No “risk-free” or guaranteed-returns language anywhere
  • Privacy policy linked in footer

Sign-off: All items green before launch.


Content-first structure makes A/B testing far more efficient than UI-first workflows — variants are pure Markdown, drafting is fast, and the frontmatter schema carries the test metadata directly into Astro.

Step 1: Define the hypothesis — Create a test file in _ab-tests/:

content-high-level/_ab-tests/hero-headline-advisors.md

Document: what you’re testing, why, and what “winning” looks like.

Step 2: Draft variants — Create variant files alongside the control:

# pages/advisors.md (existing file = control)
variant: control
ab_test_id: "hero-headline-v1"
# pages/advisors-A.md (new file = variant A)
variant: A
ab_test_id: "hero-headline-v1"

Only the tested element changes — everything else is identical.

Step 3: Import to Keystatic — Both variants appear in the Keystatic UI with their ab_test_id and variant fields.

Step 4: Astro rendering — The Astro page reads ab_test_id and variant from the content collection. The edge layer (Vercel Edge Functions, Cloudflare Workers) handles traffic splitting — 50% of visitors see control, 50% see variant A.

Step 5: Measure — PostHog or Plausible Goals tracks conversions per variant. Minimum sample sizes apply (see test files for thresholds).

Step 6: Record learnings — File a _learnings/ note. Update journey maps if the result changes your understanding of the audience.

FilePurpose
content-high-level/_ab-tests/_template.mdTemplate for new tests
content-high-level/_ab-tests/hero-headline-advisors.mdFirst test (advisor hero)
content-all/_ab-tests/_template.mdTemplate for secondary page tests
content-all/_learnings/_template.mdTemplate for recording results
  1. Advisor hero headline — “client-first framework” vs. “grow your book” messaging
  2. Investor Snapshot CTA placement — hero vs. after explanation
  3. “Borrowing to invest” vs. “$MART DEBT” — terminology preference by audience
  4. Advisor CTA label — “Book a Call” vs. “Start Free Trial”

Journey maps are strategic documents in content-high-level/_journeys/ that define the intended user paths — from stranger to happy client. They inform which content is needed at each stage and where A/B tests will have the most impact.

FileAudienceKey conversion
_journeys/advisor-journey.mdFinancial advisorsBook a Call → platform user
_journeys/investor-journey.mdIndividual investorsSnapshot complete → advisor referral

Read journey maps before designing any page. They answer: “what does this person need at this moment in their relationship with SDC?”


The workflow completes a full cycle when live performance data feeds back into content strategy:

Strategy (Step 0) → Content (Steps 1–3) → Live Site (Steps 4–6)
↑ |
_learnings/ ← Analytics + Feedback

Where learnings live: content-all/_learnings/

Each learning file captures: what was observed, what it tells us about the audience, ICP/USP implications, and action taken. Over time, this folder becomes the institutional memory of what works — Git-tracked, AI-readable.

Feedback sources (current and future):

SourceStatusWhere captured
A/B test resultsReady (at Step 5)_ab-tests/ + _learnings/
Plausible/PostHog analyticsReady (at Step 5)_learnings/
Advisor feedbackManual_learnings/
Investor Snapshot completion ratesFuture_learnings/
Visitor session recordingsFuture (Step 7+)_learnings/
Security scan resultsFuture (Step 7+)Monorepo CI/CD

This workflow is intentionally extensible. Planned additions after the core workflow is validated:

ExtensionPurposeWhen
Security scanningAutomated OWASP checks in CI/CDBefore first production deploy
Uptime monitoringAlert on downtime, performance regressionAt launch
Visitor session recordingUnderstand real user behavior (Hotjar, PostHog)After 100+ visitors
Visitor feedback widgetCollect qualitative signal directly on pagesAfter launch
Conversion funnel analysisIdentify drop-off points in advisor/investor journeysAfter 1000+ visitors
Content calendarSchedule blog posts, test launchesWhen publishing velocity matters

A full end-to-end pipeline document (from content to monitoring) is planned as a separate artifact.


AssetLocation
Core content vaultD:\FSS\Websites\SDC.com\content-high-level\
All content vaultD:\FSS\Websites\SDC.com\content-all\
Keystatic configmonorepo/sites/sdc.com/keystatic.config.ts
Localize workflowmonorepo/.github/workflows/localize.yml
Translation promptD:\FSS\Websites\SDC.com\content-all\_templates\translate-prompt.md
/content-expand skill~/.claude/commands/content-expand.md
Template site (test ground)monorepo/sites/Template/
A/B test trackingcontent-high-level/_ab-tests/, content-all/_ab-tests/
Journey mapscontent-high-level/_journeys/
Performance learningscontent-all/_learnings/

AI is effective at every stage:

StepAI Use
0Strategy refinement, ICP research
1+2Content drafting, wikilink structure
0.5Copy expansion, CTA alignment (/content-expand)
3Secondary content generation, schema validation
4Automated translation (Claude API)
5Component code generation from content specs
6Automated accessibility + SEO checks

Efficiency advantage: All AI work in Steps 1–3 is on pure Markdown — dramatically lower token cost and higher quality than working on rendered HTML/CSS.