How kmsumanth23/nitrr-clubs-and-committee1 works
Project type and purpose
• Full-stack Single-Page Application (SPA) for NIT Raipur clubs/committees.
• Users: students (public + authenticated), club officials (authorized CRUD).
• Tech stack: React + Redux front-end, Node.js + Express.js back-end, MongoDB, JWT auth.
File structure
• client/ – React app (src, components, Redux setup, public assets, build output).
• server/ – Express REST API (routes, middleware, models, server.js), MongoDB via Mongoose.
• Auth flow split between client/src/components/Auth and server/middleware/auth.js.
• CRUD routes under server/routes (auth.js, users.js, protectedRoutes.js).
README for insights
• Confirms SPA with login/register, JWT for stateless sessions.
• Club pages managed via CRUD endpoints.
• No external third-party services beyond MongoDB.
• Browser / Client (React SPA)
– React Components (Auth, Navbar, Club pages)
– Redux Store (auth state, user data)
• API Layer (Node.js/Express)
– Routes (auth.js, users.js, protectedRoutes.js)
– Middleware (JWT verification, error handlers)
– Controllers/Models (User model via Mongoose)
• Database (MongoDB)
• (Optional) Hosting/Deployment (where client build and server run)
• Browser → HTTP(S) → Express API (login, register, fetch clubs, CRUD).
• Express → MongoDB (via Mongoose queries) for persistence.
• Express → Browser (JWT tokens in response headers/body).
• Browser (Redux) stores JWT and attaches to future API calls.
c. Architectural patterns/design principles:
• Client-server separation (SPA + RESTful API).
• Stateless authentication using JWT.
• Unidirectional data flow in React + Redux.
• MVC-style structure on the server (Routes → Controllers → Models).
d. Key technologies/frameworks:
• Front-end: React.js, Redux, Create React App build artifacts.
• Back-end: Node.js, Express.js, Mongoose, JSON Web Tokens.
• Database: MongoDB.
Detail without overthinking
• Essential modules:
– React components that handle Auth and club data
– Redux store/actions/reducers
– Express middleware (auth.js)
– Route handlers (auth.js, users.js, protectedRoutes.js)
– Mongoose models (User.js)
– MongoDB instance
• Related files into logical subsystems to avoid clutter.
• Every data flow (form submission, token storage, API call) is represented.
Putting it all together:
This structured layout will give any stakeholder—from developers to operations—a clear, accurate view of how NITRR-CLUBS-AND-COMMITTEE1 is built and how its pieces interact.