Skip to content

feat(cms): extend CMS support to all frontend frameworks#102

Open
Marve10s wants to merge 1 commit intomainfrom
feat/cms-multi-framework
Open

feat(cms): extend CMS support to all frontend frameworks#102
Marve10s wants to merge 1 commit intomainfrom
feat/cms-multi-framework

Conversation

@Marve10s
Copy link
Owner

Summary

  • Extends Sanity, Strapi, and TinaCMS to work with all frontend frameworks: Next.js, Astro, Nuxt, SvelteKit, TanStack Router, React Router, React Vite, TanStack Start
  • Payload stays Next.js-only (v3 architecture requires @payloadcms/next)
  • Payload is now disabled in the web builder when non-Next.js frontend is selected
  • 81 new template files across 12 new variant directories (4 frameworks x 3 CMS)
  • Framework-aware dependency installation (@sanity/client for non-Next.js instead of next-sanity)
  • Framework-appropriate env var prefixes (VITE_*, PUBLIC_*, NUXT_PUBLIC_*)

Changes

Area Change
cms.ts handler Rewritten with variant detection (next/astro/nuxt/svelte/react)
cms-deps.ts Removed Next.js guards for Sanity/Strapi/TinaCMS
env-vars.ts Framework-aware getPublicEnvPrefix() + Strapi env vars added
add-deps.ts Added @sanity/client
compatibility.ts Added Payload-requires-Next.js disabled reason
Templates 81 new .hbs files in cms/{sanity,strapi,tinacms}/web/{react,astro,nuxt,svelte}/
Tests 13 new multi-framework CMS tests (43 total)

Test plan

  • bun test apps/cli/test/cms.test.ts — 43/43 pass
  • bun run test:release — all pass
  • bun run lint — all pass
  • Manual: --frontend astro --cms sanity generates Sanity templates
  • Manual: --frontend nuxt --cms strapi generates Strapi templates
  • Manual: --frontend svelte --cms tinacms generates TinaCMS templates
  • Manual: --frontend tanstack-router --cms payload skips Payload (Next.js only)

Sanity, Strapi, and TinaCMS now work with all frontend frameworks:
Next.js, Astro, Nuxt, SvelteKit, TanStack Router, React Router,
React Vite, and TanStack Start. Payload stays Next.js-only (v3
architecture requires @payloadcms/next).

- Rewrite CMS handler with variant detection (analytics.ts pattern)
- Framework-aware dependency installation (@sanity/client for non-Next)
- Framework-appropriate env var prefixes (VITE_, PUBLIC_, NUXT_PUBLIC_)
- 81 new template files across 4 variants per CMS
- Payload disabled in web builder for non-Next.js frontends
- 43 CMS tests passing (13 new multi-framework tests)
@vercel
Copy link

vercel bot commented Mar 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
better-fullstack-web Ignored Ignored Mar 22, 2026 3:33pm

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