Application Scaffolding Leaf MVC Only โ
Leaf MVC scaffolding creates complete feature starting points: routes, controllers, models, schema files, views, and middleware that match your app setup. You run a command, then edit real files you own.
How scaffolding works โ
Scaffolds are meant to remove repetitive setup, not hide your code. You run a command, Leaf creates the feature files, and you keep full ownership of what was generated.
If you are using Claude, Codex, or another assistant, you can ask it to scaffold a feature and then customize the generated files around your product requirements.
Every feature scaffold ships in Blade, React, Vue, and Svelte variants. Leaf detects which one to use from your app's Inertia setup, so scaffolding in a React app generates React pages without any extra flags. To pick a variant yourself, pass --scaffold react, --scaffold vue, --scaffold svelte, or --scaffold default for Blade.
Authentication โ
Authentication with Leaf is powered by Leaf Auth, which gives you login, registration, sessions, password hashing, user management, and route protection.
leaf scaffold:authThis is automatically done for you if you choose to install the application starter during installation.
Landing Page โ
Use the landing page scaffold when you want a polished starting point for your product homepage.
leaf scaffold:landing-pageBilling Subscription โ
Subscriptions are common in modern products, but the setup usually involves pricing UI, callbacks, webhooks, database state, and provider configuration. Leaf MVC can scaffold the shape for you.
leaf scaffold:subscriptionsIt requires Leaf Billing to be installed.
Waitlists โ
Waitlists help you validate demand and collect emails before a product is fully open.
leaf scaffold:waitlistBlog New โ
The blog scaffold gives you a markdown-powered blog: write posts as markdown files and Leaf renders them with your frontend setup.
leaf scaffold:blogContact form New โ
A contact form that actually sends mail, wired end to end.
leaf scaffold:contactLegal pages New โ
Every product eventually needs them, and nobody enjoys writing them from a blank file.
leaf scaffold:legalAI chat New โ
Scaffold a streaming AI chat powered by Claude: a full chat page with streamed responses, not just an API call.
leaf scaffold:aiMail setup โ
Not a feature scaffold, but a shortcut: installs Leaf Mail and generates your mail config in one step.
leaf scaffold:mailshadcn/ui New โ
If you're pairing React with your Leaf app, this sets up shadcn/ui so you can install any of its components:
leaf scaffold:shadcnpnpm dlx shadcn@latest add switchAI-assisted scaffolding โ
Scaffolding pairs naturally with AI because the command gives your assistant a working feature shape to edit instead of asking it to invent every file from scratch.
Ask your assistant:
"Scaffold auth, then customize the dashboard for a SaaS admin."Recommended workflow:
- Run or ask your assistant to run the scaffold command.
- Ask for the product-specific changes.
- Review the generated routes, controllers, models, and views.
If the assistant cannot access the project folder, run leaf context after scaffolding and paste the compact output into your conversation.
More coming soon โ
We are working on scaffolding for more features like:
- Admin panel
- API dashboard
- More product starters
