Folded is a production-style MVP boilerplate for turning Instagram Reels into clean, structured, editable recipes.
- Next.js App Router with TypeScript
- Tailwind CSS
- PostgreSQL + Prisma ORM
- Clerk authentication
- Zod validation
- Landing page for unauthenticated visitors
- Protected dashboard for authenticated users
- Provider-based import pipeline
- Mock Instagram extraction for end-to-end local development
- Structured recipe review and editing
- Serving-size scaling with fraction parsing
- Saved recipe list and import history
src/
app/ App Router routes and layouts
components/ Reusable UI components
db/ Prisma client and repositories
lib/ Env helpers and shared utilities
schemas/ Zod schemas for requests and domain types
services/ Import pipeline, normalization, validation
- Install dependencies.
- Copy
.env.exampleto.env. - Configure a PostgreSQL database.
- Configure Clerk keys.
- Run Prisma generate and migrate.
- Seed the database.
- Start the dev server.
Example commands:
npm install
npm run prisma:generate
npx prisma migrate dev --name init
npm run db:seed
npm run devFOLDED_EXTRACTOR_PROVIDER=mockkeeps the app fully functional without external ingestion services.FOLDED_EXTRACTOR_PROVIDER=placeholderuses a stub provider with explicit TODO markers for a future Instagram extraction integration.
- The app uses Clerk middleware to protect
/dashboard,/imports, and/recipes. - If Clerk keys are missing, sign-in components will not work. This is intentional for a portfolio-ready auth setup.
- Replace
PlaceholderInstagramExtractorwith a legal ingestion workflow for Instagram sources. - Swap the recipe normalizer implementation to an LLM-backed provider.
- Add screenshot upload plus OCR ingestion later using the existing import service abstraction.
- Add secure ingestion service credentials and provider-specific retry logic.
- Add background job processing if import latency grows beyond request-response comfort.
- Add analytics, observability, and audit logging before production launch.