You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Navigate to client directory firstcd client
# Development server
pnpm dev
# Build for production
pnpm build
# Lint code
pnpm lint
# Preview production build
pnpm preview
Server (Django)
# Navigate to server directory firstcd server
# Activate virtual environmentsource .venv/bin/activate
# Install dependencies
pip install -r requirements.txt
# Run development server
python manage.py runserver
# Create and apply database migrations
python manage.py makemigrations
python manage.py migrate
# Create superuser
python manage.py createsuperuser
# Collect static files (for production)
python manage.py collectstatic
Project Architecture
Technology Stack
Frontend: React 19 with Vite, Redux Toolkit (RTK Query), Ant Design, GSAP animations
Backend: Django 5.0.3 with Django REST Framework, JWT authentication
Database: PostgreSQL (via Docker)
State Management: Redux Toolkit with RTK Query for API calls
Styling: CSS modules with Ant Design components
Package Manager: pnpm for frontend dependencies
Directory Structure
MujBlog/
├── client/ # React frontend application
│ ├── src/
│ │ ├── Components/ # React components organized by type
│ │ ├── Routers/ # React Router configuration
│ │ ├── redux/ # Redux store and RTK Query slices
│ │ ├── Axios/ # Axios configuration and interceptors
│ │ └── assets/ # Static assets (CSS, images)
└── server/ # Django backend application
├── api/ # REST API endpoints and views
├── blog/ # Blog app with models and views
├── config/ # Django settings and configuration
└── uploads/ # Media files storage
Frontend Architecture
Component Organization
Layout Components: AdminLayout, RootLayout - provide different layouts for admin vs public pages
Page Components: HomePage, AdminPage, GalleryPage, AuthPage - main page components
Template System: Uses PageTemplate component to combine layout and content
State Management
Redux Store: Configured with RTK Query for API state management