A Modern Full-Stack Social Media Experience
Built with the MERN Stack, featuring Glassmorphism UI, Smart Search, and Advanced Admin Controls.
Experience the platform live:
SnapPost Live Deployment
This repository represents v2.0 of SnapPost.
This version introduces a complete architecture migration, transition from EJS to React, and a mobile-first UI strategy.
Legacy Build: You can find the original EJS-based version here:
SnapPost v1.0 Legacy 🔗
- JWT: Secure token-based authentication.
- Role-Based Access: Dedicated Admin routes and protected middleware.
- Ownership Validation: Strict server-side checks for editing/deleting content.
- MERN CRUD: Create, read, update, and delete posts seamlessly.
- Media Handling: Image integration via Multer and Cloudinary storage.
- Engagement: Real-time like system and nested comment threads.
- Debounced API: Optimized search functionality for reduced server load.
- Mobile Search: Full-screen modal search specifically designed for small viewports.
- Theme Engine: Instant Dark/Light mode toggle via React Context.
📦 SnapPost_Backend
┣ 📂 Cloudinary # Cloud image storage configuration
┣ 📂 Controllers # Business logic handlers
┣ 📂 Middleware # Auth & Admin verification logic
┣ 📂 Models # Mongoose Schemas (User, Post, Comment)
┣ 📂 uploads # Local temporary file storage
┣ 📂 Utils # Helper functions & token utilities
┣ 📂 views # Admin EJS templates
┣ 📜 multer.js # Middleware for handling multipart/form-data
┗ 📜 server.js # Application entry point
📦 SnapPost_Frontend
┣ 📂 src
┃ ┣ 📂 API # Axios instances and endpoint definitions
┃ ┣ 📂 assets # Global static assets and icons
┃ ┣ 📂 Components # Reusable UI elements (NavBar, Toast, Loader)
┃ ┣ 📂 Context # Global state management (Theme, User)
┃ ┣ 📂 Pages # Route components (Home, Profile, Admin)
┃ ┣ 📂 Sections # Feature-specific page fragments
┃ ┣ 📂 Utils # Formatting & Token validators
┃ ┣ 📜 App.jsx # Main router and layout configuration
┃ ┗ 📜 index.css # Global Tailwind and custom styles
┗ 📜 vite.config.js
- To access the terminal, the user should log in through admin credentials.
- Unified Dashboard: Real-time overview of all registered creators.
- User Management: Secure search and "Suspend/Remove" capabilities.
- Cascade Logic: Automated deletion of all associated posts and comments when a user is removed to ensure database integrity.