An ephemeral newsletter platform where creators can share daily content through personalized bio links.
- Node.js 18+
- pnpm
- PostgreSQL database (local or Supabase)
-
Install dependencies:
pnpm install
-
Set up environment variables:
cp .env.example .env.local
Update
.env.localwith your actual values:DATABASE_URL: Your PostgreSQL connection stringNEXT_PUBLIC_SUPABASE_URL: Your Supabase project URLNEXT_PUBLIC_SUPABASE_ANON_KEY: Your Supabase anonymous keySUPABASE_SERVICE_ROLE_KEY: Your Supabase service role key
-
Set up the database:
pnpm db:push pnpm db:seed
-
Start the development server:
pnpm dev
src/
├── app/ # Next.js app router pages
│ ├── [username]/ # Dynamic creator bio link pages
│ ├── auth/ # Authentication pages
│ ├── dashboard/ # Creator dashboard
│ └── creator/ # Creator profile pages
├── components/ # React components
│ ├── auth/ # Authentication components
│ ├── dashboard/ # Dashboard components
│ ├── reader/ # Reader experience components
│ └── ui/ # Reusable UI components
├── hooks/ # Custom React hooks
└── lib/ # Utility functions and configurations
├── prisma.ts # Prisma client
├── supabase.ts # Supabase client
└── utils.ts # General utilities
- Framework: Next.js 15 with App Router
- Database: PostgreSQL with Prisma ORM
- Authentication: Supabase Auth
- Styling: Tailwind CSS with custom theme
- UI Components: Radix UI + shadcn/ui
- Type Safety: TypeScript
- User profile information and branding
- Links to Supabase auth user ID
- Stores custom brand colors and bio
- Daily newsletter content
- Markdown content with cover images
- Reading time estimation
- Tracks user interactions
- Event types: impressions, reads, subscribe clicks
- Stores user agent and referrer data
The platform uses a custom theme based on:
- Primary Color:
#d87943(warm orange) - Secondary Color:
#527575(teal) - Fonts: Geist Mono for sans-serif, JetBrains Mono for monospace
pnpm dev- Start development serverpnpm build- Build for productionpnpm start- Start production serverpnpm lint- Run ESLintpnpm db:generate- Generate Prisma clientpnpm db:push- Push schema to databasepnpm db:migrate- Run database migrationspnpm db:seed- Seed database with sample data
Use shadcn/ui for consistent component patterns:
npx shadcn@latest add <component-name>- Update
prisma/schema.prisma - Run
pnpm db:pushfor development - Run
pnpm db:generateto update types
✅ Task 2 Complete: Backend infrastructure setup
- Supabase project configuration
- Prisma ORM setup with database schema
- UI components copied and configured
- Custom theme colors applied
- Development environment ready
Next Steps: Task 3 - Implement authentication system