A modern web-based photo booth built with Svelte 5, SvelteKit, and Tailwind CSS. Capture photo strips with customizable layouts and frames directly in your browser.
š Live Demo ⢠Features ⢠Getting Started ⢠Development
# Clone the repository
git clone https://github.com/AungMyoKyaw/photo-booth.git
cd photo-booth
# Install dependencies
bun install
# or
npm install
# Start development server
bun run dev
# or
npm run dev
Open http://localhost:5173 in your browser.
bun run build
bun run preview
This project is deployed on Cloudflare Workers using @sveltejs/adapter-cloudflare.
# Deploy to Cloudflare Workers
bun run build
npx wrangler deploy
Live Demo: https://photo-booth.aungmyokyaw.workers.dev/
photo-booth/
āāā src/
ā āāā lib/
ā ā āāā components/ # Svelte components
ā ā ā āāā Camera.svelte # Camera preview with switching
ā ā ā āāā Countdown.svelte # 3-second countdown timer
ā ā ā āāā FrameSelector.svelte # Frame color picker
ā ā ā āāā Gallery.svelte # Photo strip gallery
ā ā ā āāā LayoutSelector.svelte # Layout picker (2Ć2 / 4Ć1)
ā ā ā āāā PhotoStrip.svelte # Current strip preview
ā ā āāā stores/ # State management (Svelte 5 runes)
ā ā ā āāā photos.svelte.ts
ā ā āāā types/ # TypeScript types
ā ā ā āāā photo.ts
ā ā āāā utils/ # Utility functions
ā ā āāā canvas.ts # Photo strip generation
ā āāā routes/ # SvelteKit routes
ā ā āāā +layout.svelte # Root layout
ā ā āāā +page.svelte # Main page
ā ā āāā layout.css # Global styles
ā āāā app.html # HTML template
āāā static/ # Static assets
āāā package.json
āāā svelte.config.js
āāā tsconfig.json
āāā vite.config.ts
| Command | Description |
|---|---|
npm run dev |
Start development server |
npm run build |
Build for production |
npm run preview |
Preview production build |
npm run check |
Run type checking |
npm run lint |
Run Prettier + ESLint |
npm run format |
Format with Prettier |
npm run test |
Run tests with Vitest |
$state, $derived, $props)Contributions are welcome! Here's how you can help:
git checkout -b feature/amazing-feature)git commit -m 'Add amazing feature')git push origin feature/amazing-feature)This project is licensed under the MIT License - see the LICENSE file for details.
Made with ā¤ļø by Aung Myo Kyaw
Built with Svelte 5 ⢠š¤ GLM 4.7