A Next.js application for connecting Indian nurses with opportunities in Germany, featuring a blog system and webinar content management with a full-featured admin panel.
- π Blog System: Dynamic blog posts with rich content
- π₯ Webinar Management: YouTube Shorts integration
- π Admin Panel: Secure content management system
- ποΈ PostgreSQL Database: Powered by Neon DB
- β‘ ISR: Incremental Static Regeneration for optimal performance
- π¨ Modern UI: Built with Tailwind CSS and Framer Motion
- Framework: Next.js 16 (App Router)
- Database: PostgreSQL (Neon DB)
- ORM: Prisma 7
- Authentication: JWT with bcryptjs
- Styling: Tailwind CSS
- Animations: Framer Motion
- Language: TypeScript
- Node.js 18+ installed
- A Neon DB account (neon.tech)
-
Clone the repository
git clone <repository-url> cd taldo
-
Install dependencies
npm install
-
Set up environment variables
Create a
.envfile in the root directory:# Database Connection (from Neon dashboard) DATABASE_URL="postgresql://user:password@host/database?sslmode=require" # Admin Authentication # Generate hash: node -e "console.log(require('bcryptjs').hashSync('your-password', 10))" ADMIN_PASSWORD_HASH="$2a$10$your-generated-hash" # JWT Secret (generate a random string) JWT_SECRET="your-secret-key-min-32-characters" # Base URL NEXT_PUBLIC_BASE_URL="http://localhost:3000"
-
Run database migrations
npx prisma migrate dev
-
Seed the database
npx prisma db seed
-
Start development server
npm run dev
Visit http://localhost:3000 to see the application.
taldo/
βββ prisma/
β βββ schema.prisma # Database schema
β βββ seed.js # Data seeding script
β βββ migrations/ # Database migrations
βββ src/
β βββ app/
β β βββ admin/ # Admin panel routes
β β βββ api/ # API routes
β β βββ blog/ # Blog pages
β β βββ webinar/ # Webinar page
β βββ components/
β β βββ admin/ # Admin components
β β βββ webinar/ # Webinar components
β βββ lib/
β β βββ prisma.ts # Prisma client
β β βββ auth.ts # Auth utilities
β βββ data/ # JSON data (for reference)
βββ public/ # Static assets
βββ prisma.config.ts # Prisma configuration
Access the admin panel at /admin with your configured password.
- π Dashboard with statistics
- βοΈ Create, edit, and delete blog posts
- π¬ Manage YouTube Shorts (webinars)
- πΌοΈ Image upload functionality
- π Search and filter content
GET /api/blogs- Get all published blogsGET /api/blogs/[id]- Get single blogPOST /api/blogs- Create blog (admin)PUT /api/blogs/[id]- Update blog (admin)DELETE /api/blogs/[id]- Delete blog (admin)
GET /api/webinars- Get all published webinarsPOST /api/webinars- Create webinar (admin)PUT /api/webinars/[id]- Update webinar (admin)DELETE /api/webinars/[id]- Delete webinar (admin)
POST /api/auth/login- Admin loginPOST /api/auth/logout- Admin logoutGET /api/auth/me- Check auth status
POST /api/upload- Upload images (admin)
id: Unique identifierslug: URL-friendly identifiertitle: Blog titledate: Publication dateimage: Featured image URLintro: Introduction textparagraphs: Content paragraphs (array)bulletPoints: Key points (array)published: Publication statuscreatedAt,updatedAt: Timestamps
id: Unique identifiervideoId: YouTube video IDtitle: Optional titledescription: Optional descriptionorder: Display orderpublished: Publication statuscreatedAt,updatedAt: Timestamps
# Development
npm run dev # Start dev server
npm run build # Build for production
npm run start # Start production server
# Database
npx prisma studio # Open Prisma Studio
npx prisma migrate dev # Create migration
npx prisma db seed # Seed database
npx prisma generate # Generate Prisma Client
# Linting
npm run lint # Run ESLint| Variable | Description | Required |
|---|---|---|
DATABASE_URL |
PostgreSQL connection string | Yes |
ADMIN_PASSWORD_HASH |
Bcrypt hash of admin password | Yes |
JWT_SECRET |
Secret for JWT tokens | Yes |
NEXT_PUBLIC_BASE_URL |
Base URL for API calls | Yes |
- Push your code to GitHub
- Import project in Vercel
- Add environment variables
- Deploy
- Build the application:
npm run build - Set environment variables
- Run migrations:
npx prisma migrate deploy - Start server:
npm start
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is private and proprietary.
For support, email support@taldo.com or open an issue in the repository.