Skip to content

feat(public): homepage use-cases section + shared markdown renderer#15

Merged
mastermanas805 merged 1 commit into
mainfrom
feat/homepage-use-cases-and-renderer-upgrade
May 11, 2026
Merged

feat(public): homepage use-cases section + shared markdown renderer#15
mastermanas805 merged 1 commit into
mainfrom
feat/homepage-use-cases-and-renderer-upgrade

Conversation

@mastermanas805
Copy link
Copy Markdown
Member

What changed

Two changes shipped together:

  1. Homepage use-cases section/use-cases was missing from the marketing front door. Adds a "Use cases · 100+ shapes the platform fits" section between the how-it-works and pricing teasers. 6 curated exemplar cards link to /use-cases/<slug> + a "See all 104" CTA.

  2. Shared markdown renderer at src/lib/markdown.tsx. The three pages that render body content (BlogPostPage, DocsPage, UseCaseDetailPage) had near-identical custom renderers. Consolidated into one module that adds: numbered lists, markdown links with href safety check, blockquotes, ASCII tables. Configurable baseHeading per call site so headings nest correctly under each page's existing structure.

Why the renderer upgrade

The 104 use-case detail bodies (being authored in parallel — 4 background agents, batches 2 and 4 already done) need to render numbered steps and inline links. The custom renderers didn't support either. The shared module also kills ~240 lines of duplicated parsing code.

Verification

  • npm run build ✓ — 115 static HTML files
  • Homepage: 6 mkt-uc-card entries with correct slugs + "See all 104 use cases →" CTA
  • /docs/index.html: tier-limits table renders via .md-table class (preserved from old renderer)
  • /blog/why-anonymous-is-the-trial/index.html: 1 h1 + 3 h2 (matches pre-migration output)
  • Security scan clean (href whitelist blocks javascript: / data: schemes; XSS hardened)

Follow-up

  • Content commit lands when remaining 2 authoring agents complete: 104 detail bodies with sample prompt + steps for each case
  • /use-cases/<slug> "Detail" section will render that hand-authored body via the new renderer; auto-generated "How to set it up" + "Why this is useful" sections stay as-is

🤖 Generated with Claude Code

Two changes that ship together:

1. Homepage use-cases section. /use-cases was missing from the
   marketing front door. Adds a "Use cases · 100+ shapes the
   platform fits" section between the how-it-works and pricing
   teasers. Renders 6 curated exemplar cards (one per major
   archetype: ephemeral test DB, one-afternoon MVP, agent memory,
   LangGraph fan-out, Devin-style PR bot, Stripe webhook handler)
   plus a "See all 104 use cases →" CTA. Cards link to
   /use-cases/<slug>; missing slugs simply skip rendering — no
   broken links.

2. Shared markdown renderer at src/lib/markdown.tsx. The three
   places that render body content (UseCaseDetailPage,
   BlogPostPage, DocsPage) all had near-identical inline
   renderMarkdown + inline functions with subtly different
   behaviours. Consolidated into one module with:

   - Heading levels h1–h6 (was h2–h6 before; needed for blog `#`)
   - Numbered lists `1. foo` → <ol> (was unsupported)
   - Markdown links `[text](url)` with href safety check
     (http/https/anchor/internal-route only; blocks javascript:)
   - Blockquotes `> ` → <blockquote>
   - ASCII tables `|` → <pre class="md-table"> (preserves /docs
     limits-table behaviour from the old DocsPage renderer)
   - Configurable baseHeading per call site so headings nest
     correctly under each page's existing h1/h2 wrappers
   - keyPrefix option to avoid React-key collisions when one
     parent renders multiple bodies

   BlogPostPage, DocsPage, UseCaseDetailPage now import from
   src/lib/markdown. The three sites of duplication (~80 lines
   each) are gone.

Verified: npm run build → 115 static HTML files. Homepage shows 6
cards with correct slugs + "See all 104" CTA. /docs renders the
tier-limits table via .md-table class. /blog/<slug> still renders
its headings unchanged. /use-cases/<slug> detail body section
remains empty (auto-generated detail still renders); next content
commit will populate all 104 bodies via 4 parallel authoring
agents.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@mastermanas805 mastermanas805 merged commit 23ffb81 into main May 11, 2026
1 of 2 checks passed
@mastermanas805 mastermanas805 deleted the feat/homepage-use-cases-and-renderer-upgrade branch May 11, 2026 11:48
mastermanas805 added a commit that referenced this pull request May 11, 2026
…nt (#23)

InstaNode-dev/api PR #15 just landed — the agent API now serves
GET /api/v1/billing as the aggregated subscription-state endpoint
the dashboard had been fixturing.

This commit drops the fixture path. fetchBilling() now calls the
real endpoint and maps the response into the dashboard's existing
BillingDetails shape (status, current_period_end, payment_last4,
payment_network — every field the agent API can populate is now
live; the ones the agent API doesn't expose yet stay undefined and
render as "—" in the UI).

Fallback: on 503 (Razorpay unconfigured in local dev), still falls
back to FIXTURE_BILLING so the BillingPage doesn't break for
developers without RAZORPAY_KEY_ID set. Any other error propagates
so production failures aren't silently swallowed.

Closes the partial-fixture comment block I left in PR #20.

Verified: npm run build clean (116 HTML + 116 .md), 26/26 markdown
renderer tests pass, Playwright auth/navigation/resources specs
all green.

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant