A modern, scalable ride-hailing platform for seamless urban mobility.
- Project Overview
- Features
- Tech Stack
- Folder Structure Overview
- Getting Started
- Environment Variables
- Deployment
- Contributing
- License
- Preview / Screenshots
SwiftRide is a next-generation ride-hailing and transport booking platform designed for fast, reliable, and secure urban travel. With real-time ride tracking, intuitive booking, and a robust driver dashboard, SwiftRide empowers both riders and drivers for a smooth journey every time.
- Purpose: Connects passengers and drivers for on-demand rides.
- Core Benefits:
- Fast and secure ride booking
- Real-time location tracking
- Transparent pricing and payment
- User-friendly experience for both riders and drivers
- π Real-time ride tracking
- π± Easy ride booking & cancellation
- π Secure user authentication (JWT)
- π³ Payment integration (placeholder)
- π§β
βοΈ Driver dashboard & management - πΊοΈ Live map and route calculation
- π Ride history & analytics
- π© Notifications (placeholder)
- π‘οΈ Role-based access (user/driver)
Frontend:
Backend:
Node.js with Express.js
MongoDB (Mongoose)
Socket.io (real-time updates)
JWT (Authentication)
Express Validator
Other Tools:
SwiftRide/
βββ frontend/ # React app (Vite, TailwindCSS)
β βββ src/
β β βββ components/ # Reusable UI components
β β βββ pages/ # Main app pages (Home, Login, etc.)
β β βββ context/ # React context providers
β β βββ assets/ # Images, icons, etc.
β βββ public/ # Static files
βββ backend/ # Node.js/Express API
β βββ controllers/ # Route controllers (user, ride, captain, etc.)
β βββ models/ # Mongoose schemas
β βββ routes/ # Express route definitions
β βββ services/ # Business logic/services
β βββ db/ # Database connection
β βββ socket.js # Socket.io logic
β βββ app.js # Express app setup
β βββ server.js # Server entry point
βββ package.json # Project metadata/scripts
βββ README.md # Project documentation
Descriptions:
frontend/: All client-side code and UIbackend/: All server-side logic and API endpointscontrollers/,models/,routes/,services/: Modular backend structuredb/: Database connection logicsocket.js: Real-time communication
git clone https://github.com/your-username/SwiftRide.git
cd SwiftRidecd frontend
npm installcd ../backend
npm install- Copy
.env.exampleto.envin bothfrontend/andbackend/directories (if applicable). - Fill in the required values (see Environment Variables).
npm run dev
# Runs on http://localhost:5173npm run dev
# Runs on http://localhost:5000- Create a
.envfile in bothfrontend/andbackend/directories as needed. - Example placeholders:
VITE_API_URL=http://localhost:5000DATABASE_URL=mongodb://localhost:27017/swiftrideJWT_SECRET=your_jwt_secretGOOGLE_MAPS_API_KEY=your_api_key
- Never commit secrets to version control.
- Build the frontend:
cd frontend
npm run build- Deploy the
dist/folder to Vercel or Netlify. - Set environment variables in your hosting platform dashboard.
- Ensure your
package.jsonhas a start script:
"scripts": {
"start": "node server.js"
}- Push your code to GitHub and connect to your hosting platform.
- Configure environment variables (DATABASE_URL, JWT_SECRET, etc.) in your hosting dashboard.
- Deploy and your backend API will be live!
- Use production-ready MongoDB instance (e.g., MongoDB Atlas).
- Enable CORS for frontend-backend communication.
- Use HTTPS in production for secure data transmission.
We welcome contributions! To get started:
- Fork the repository
- Create a new branch (
git checkout -b feature/your-feature) - Commit your changes (
git commit -m 'Add new feature') - Push to your branch (
git push origin feature/your-feature) - Open a Pull Request (PR)
Coding Style:
- Use clear, descriptive commit messages
- Follow existing code style and structure
- Write clean, maintainable code
This project is licensed under the MIT License. See the LICENSE file for details.
Add screenshots, GIFs, or demo links here to showcase SwiftRideβs UI and features!
SwiftRide β Modern mobility, made simple.