Welcome to Blogify! A robust, full-stack blogging application built using the latest modern web technologies. Blogify is designed to provide a seamless experience for both readers and content creators, featuring a secure admin dashboard, responsive design, and intuitive user interfaces.
| Feature | Technology |
|---|---|
| Core Framework | Next.js 16 (App Router) |
| Frontend | React 19, TailwindCSS 4 |
| Database | MongoDB via Mongoose |
| Authentication | JWT (jose & jsonwebtoken), Bcrypt.js |
| State/UI | React Toastify, Axios |
| Deployment | Vercel |
-
Secure Authentication:
- Full Signup/Login flow with hashed passwords.
- JWT based cookies for persistent user sessions.
- Protected admin routes using Next.js Middleware.
-
Admin Dashboard:
- Manage blogs directly from a dedicated interface.
- Add, edit, or delete blog posts effortlessly.
-
Email Subscriptions:
- Integrated subscription system for readers to stay updated.
-
Fully Responsive:
- Seamless browsing experience across mobile, tablet, and desktop.
-
Supercharged Performance:
- Powered by Next.js Server Side Rendering (SSR) and Client Side Hydration.
Blogify/
├── app/ # Next.js App Router (pages & API routes)
│ ├── admin/ # Protected Admin pages
│ ├── api/ # Backend API endpoints (Auth, Blog, Email)
│ ├── blogs/ # Public blog view pages
│ ├── login/ # Login authentication page
│ ├── signup/ # Signup authentication page
│ └── profile/ # User profile management
├── Assets/ # Static assets, icons, and blog images
├── Components/ # Reusable UI components (Header, Footer, BlogItems, etc.)
├── lib/ # Shared logic & configurations
│ ├── config/ # DB connection & environment setup
│ └── models/ # Mongoose Schemas (User, Blog, Email)
├── middleware.js # Auth guarding and route redirection
├── public/ # Public static assets
└── package.json # Project dependencies and script runner
Follow these steps to set up and run Blogify locally.
- Node.js: v18.x or higher
- MongoDB: A running instance (local or Atlas)
- Environment Variables: Create a
.env.examplefile in the root with your credentials:MONGODB_URI=your_mongodb_connection_string JWT_SECRET=your_jwt_secret_key
-
Clone the repository:
git clone https://github.com/jindalharry07/Blogify.git cd Blogify -
Install dependencies:
npm install
-
Run the development server:
npm run dev
-
Visit the app: Open http://localhost:3000 to see Blogify in action!
Blogify uses a sophisticated Middleware layered security:
- Public Routes:
/,/login,/signupare accessible to all. - Redirection: Authenticated users are automatically redirected away from
/login//signup. - Admin Protection: Only users with the
adminrole can access/admin. This is enforced at the server-edge usingjoseJWT verification.
Contributions are welcome! If you'd like to improve Blogify, feel free to fork the repo and submit a PR.
- Fork it!
- Create your feature branch:
git checkout -b feature/awesome-feature - Commit your changes:
git commit -m 'Add some feature' - Push to the branch:
git push origin feature/awesome-feature - Submit a pull request!
This project is licensed under the MIT License - see the LICENSE file for details.
Developed with ❤️ by jindalharry07.