A modern, responsive photo gallery application built with Next.js, Convex, and Clerk for authentication. Users can create albums, upload photos, and share with others.
- Secure authentication with Clerk
- Real-time database with Convex
- Create public or private albums
- Upload, edit, and categorize photos
- Search and explore public photos
- Tag-based organization
- Responsive design with Tailwind CSS
- Frontend: Next.js, React, Tailwind CSS
- Backend: Convex for database and file storage
- Authentication: Clerk
- State Management: React hooks with Convex client
- UI Components: Custom components with Tailwind
- Node.js (v16+)
- npm or yarn
- Clerk account
- Convex account
-
Clone the repository:
git clone https://github.com/e-nk/memoria.git cd memoria -
Install dependencies:
npm install
-
Configure environment variables:
# Create a .env.local file with your credentials NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=your_clerk_pub_key CLERK_SECRET_KEY=your_clerk_secret_key NEXT_PUBLIC_CLERK_SIGN_IN_URL=/sign-in NEXT_PUBLIC_CLERK_SIGN_UP_URL=/sign-up NEXT_PUBLIC_CLERK_AFTER_SIGN_IN_URL=/home NEXT_PUBLIC_CLERK_AFTER_SIGN_UP_URL=/home CLERK_WEBHOOK_SECRET=your_webhook_secret NEXT_PUBLIC_CONVEX_URL=your_convex_deployment_url -
Initialize Convex:
npm convex dev
-
Run the development server:
npm run dev -
Open http://localhost:3000 in your browser.
- Create a Convex account at convex.dev
- Set up a new project and copy your deployment URL
- Configure Convex schema and functions from the project files
- Create a Clerk account at clerk.dev
- Set up a new application
- Configure OAuth providers (Google, GitHub, etc.) as needed
- Add your domain to the allowed origins
- Configure webhooks with
/api/webhooks/clerkas the endpoint
/app # Next.js app router
/(home) # Authenticated routes
/home # Main home page after login
/album/[id] # Album detail page
/photo/[id] # Photo detail page
/albums # User's albums page
/explore # Explore photos page
/components # React components
/convex # Convex schema and functions
/hooks # Custom React hooks
/utils # Utility functions
/public # Static filesMainLayout:Base layout with background effectsAuthLayout:Layout for authenticated pagesAlbumsList:Displays album grid with photo previewsPhotoGrid:Displays photos in a responsive gridPhotoUpload:Handles photo uploadingPhotoEditor:Edits photo metadata
MIT
Contributions are welcome! Please feel free to submit a Pull Request.