A modern event management platform built with React, TypeScript, and FSD (Feature-Sliced Design) architecture.
This project follows Feature-Sliced Design architecture, a methodology that organizes code into logical and independent layers:
src/
βββ app/ # App Layer - Global configuration
β βββ router/ # Application routing
β βββ store/ # Redux store configuration
βββ entities/ # Entities Layer - Reusable business logic
β βββ chat/ # Chat entities, messages API (REST + types)
β βββ event/
β βββ registration/ # Event registration API (RTK Query)
β βββ category/
β βββ currency/
β βββ organizer/
βββ features/ # Features Layer - User functionalities
β βββ auth/ # Authentication
β βββ event-chat/ # Real-time event chat (Socket.IO)
β βββ event-side-panel/ # Admin preview: messages tab, participants
β βββ registration/ # Customer registration form (modal)
β βββ like-event/ # Event likes
βββ pages/ # Pages Layer - Page components
β βββ admin/ # Admin pages
β βββ auth/ # Auth pages
β βββ customer/ # Customer pages
βββ shared/ # Shared Layer - Shared code
β βββ api/ # API configuration
β βββ lib/ # Utilities
β βββ ui/ # Generic UI components
β βββ config/ # Global configuration
βββ widgets/ # Widgets Layer - Complex components
- Separation of Concerns : Each layer has a well-defined role
- Independence : Features are independent and reusable
- Scalability : Architecture that evolves with complexity
- Maintainability : Organized and easy-to-maintain code
- React 19 : UI library with modern hooks
- TypeScript : Static typing for code robustness
- Vite : Ultra-fast build tool for development
- Ant Design : Admin UI components (tables, forms, tabs)
- Redux Toolkit : Simplified state management with RTK Query
- Redux Persist : Client-side data persistence
- RTK Query : API calls management with built-in cache
- React Router 7 : Declarative routing with nested routes
- Private routes : Authentication-protected segments (
PrivateRoute)
- Tailwind CSS : Utility-first CSS framework
- Lucide React : Modern and consistent icons
- Zod : TypeScript-first schema validation
- React Hook Form : Performant forms with validation
- JSON Server : REST resources under
/api(events, registrations, messages, etc.) - Custom Node server : Auth routes,
POST /api/registrations(emails + DB), Socket.IO - Socket.IO : Real-time chat on the same origin as
VITE_API_URL - Nodemailer (backend) : Transactional email (Gmail or compatible SMTP)
- Login/Register with validation
- JWT token management (simulated)
- Protected routes with PrivateRoute
- Session persistence with Redux Persist
- Dashboard with statistics
- Event CRUD management
- Category management
- Currency management
- Organizer management
- Event preview
- City management
- Per-event rooms : Clients
joinwitheventId; server replays history fromdb.json - Live messages :
messageevents broadcast to everyone in the room; messages persisted server-side - Typing indicator :
typingevent with short-lived UI feedback for other participants - Read receipts :
seensyncsseenByon messages and broadcasts updates - Optimistic UI : Outgoing messages appear immediately, then reconcile when the server echoes
- Authenticated users : Chat hooks use the logged-in user (
userId/ display from session) - Admin replies :
admin_replyemits a highlighted message and can trigger email to a participant (see below) - Where it appears : Floating chat on the events listing page; Messages tab in the admin event preview side panel
Implemented in the custom API (see api-server/server.js in this repo as a reference to deploy next to db.json).
- Event registration (
POST /api/registrations) : creates the registration, updates event participants andavailableSeats, responds immediately, then sends emails asynchronously (avoids the client hanging on SMTP) - Participant : confirmation email (free event); for paid events, confirmation plus a second email with payment link (
FRONTEND_URL/payment/β¦) - Administrator : optional new registration alert to
ADMIN_EMAILor to the organizer email resolved fromorganizers+event.organizerId - From admin chat :
admin_replywithtypepayment|info|chatsends the corresponding template touserEmail - Requirements :
EMAIL_USER,EMAIL_PASS(e.g. Gmail app password),FRONTEND_URL, and optionallyADMIN_EMAIL
- Modal form : name, email, phone; supports free and paid events
- API :
POST /api/registrationswithnumberOfTickets(client sends1by default) - Client timeout : registration requests abort after 45s so the UI does not spin forever if the API stalls
- After success : cache refresh via
getEventById.initiateso seats and participants stay in sync (no duplicate PATCH when the backend already updates the event)
- Event listing with filters (category, price, city, sort, search)
- Event detail page with ticket card and registration
- Favorites / likes (persisted)
- Responsive layout
- Dashboard, CRUD for events, categories, currencies, organizers, cities
- Event preview : side panel with Messages (same chat stack as customers, plus admin reply) and Participants
- Node.js 18+
- npm or yarn
# Clone the project
git clone https://github.com/rudney5000/Event-Management-Platform.git
cd Event-Management-Platform
# Install dependencies
npm install
# Start development server
npm run dev-
Data : maintain
db.json(users,events,registrations,messages,organizers, β¦). Add anemailfield on organizers if you rely on organizer-based admin notifications. -
Run the full stack (recommended) : use the custom
server.js(reference copy inapi-server/server.js) so you get:POST /auth/login,POST /auth/register(user signup β not event registration)POST /api/registrations(event registration + emails)POST /auth/refresh- JSON Server under
/api - Socket.IO on the same HTTP server
-
Deploy (e.g. Render) : start command must run this Node app, not the
json-serverCLI alone, otherwise chat and mail logic will not run. -
Environment variables (API) :
PORT=3001
FRONTEND_URL=https://your-frontend.example.com
EMAIL_USER=your@gmail.com
EMAIL_PASS=your-app-password
ADMIN_EMAIL=you@example.com- Frontend :
VITE_API_URL=https://your-api.example.comThe Socket.IO client connects to the same VITE_API_URL (websocket transport).
- LoginForm β
useLoginMutationβ API Call - API Response β Redux Actions β State Update
- State Update β PrivateRoute Validation β Navigation
- RTK Query : Automatic caching and synchronization
- Redux Persist : Auth slice whitelist (
user,accessToken,refreshToken,isAuthenticated); likes slice persisted separately - Zod Validation : API response validation
Each feature follows the FSD structure:
feature/
βββ api/ # API calls (RTK Query)
βββ model/ # Types, schemas, constants
βββ slice/ # Redux slices
βββ ui/ # Feature UI components
βββ hooks/ # Custom hooks
VITE_API_URL=https://event-management-platform-api.onrender.comUsed for REST (RTK Query) and for the Socket.IO client (VITE_API_URL).
- SerializableCheck : Disabled for redux-persist
- Middleware : RTK Query + persistence
- DevTools : Enabled in development
npm run dev # Development server
npm run build # Production build
npm run preview # Preview build
npm run lint # ESLint- FSD Layers : Strict layer adherence
- Feature Independence : Self-sufficient features
- Type Safety : TypeScript strict mode
- Error Boundaries : Error handling
- Code Splitting : Lazy loading of routes
- Memoization : React.memo, useMemo, useCallback
- Optimistic Updates : Optimistic updates with RTK Query
- Input Validation : Zod for all inputs
- Route Protection : PrivateRoute with validation
- Token Management : Secure token storage
- Create Feature :
src/features/new-feature/ - Define Types :
model/types.ts - Implement API :
api/newFeatureApi.ts - Create Slice :
slice/newFeatureSlice.ts - Develop UI :
ui/components/ - Add Pages :
pages/feature-page/ - Configure Routes :
app/router/router.tsx
FSD Architecture β’ TypeScript β’ Modern React