π Global Bazaar Live Site: https://windy-cast.surge.sh
This repository contains the frontend of GlobalBazaar, an e-commerce platform built with React, Vite, and TailwindCSS.
- Product Catalog with filtering by category
- Shopping Cart functionality
- JWT Authentication (Login/Register)
- Order Management
- Responsive Design for all devices
- Frontend: React.js
- Styling: TailwindCSS + DaisyUI
- State Management: React Query / Context API
- Routing: React Router DOM
- Build Tool: Vite
- Node.js (v18+)
- Yarn or npm
# 1. Clone the repository
git clone <frontend-repo-url>
cd globalbazaar-frontend
# 2. Install dependencies
yarn install # or npm install
# 3. Configure environment variables
Create a .env file with:
VITE_API_BASE_URL=http://localhost:3000
yarn dev # or npm run dev
App will run at: http://localhost:5173
src/
βββ assets/ # Static assets
βββ components/ # Reusable components
βββ contexts/ # Context providers
βββ hooks/ # Custom hooks
βββ pages/ # Page components
βββ routes/ # App routing
βββ services/ # API service functions
βββ styles/ # Global styles
βββ utils/ # Utility functions
The frontend communicates with these backend endpoints:
POST / jwt; // Gets JWT token
GET /get-allProducts // All products
GET /singleProduct/:id // Single product details
GET /filterCategory?category=:category // Filter by category
POST /orders // Create new order
GET /getAllOrder/:email // Get user's orders
DELETE /orders/:id // Cancel order
- Marquee Animation for featured products
- Quantity Update system
- Toast Notifications for user actions
- Loading Skeletons for better UX
MIT License
Note for Developers:
- Always use environment variables for API base URLs
- Implement proper error handling for API calls
- Follow React best practices for component structure