This is a single-page application (SPA) for an e-commerce platform built with React, Vite, Chakra UI, and Tailwind CSS. It allows users to browse products, add them to the cart, and proceed to checkout.
You can access the web page for the chat application at the following URL:
E-Commerce SPA Project Web Page
Clone the repository:
git clone https://github.com/yourusername/ecommerce-spa-project.git
cd ecommerce-spa-project
Install dependencies:
npm install
Create a .env
file in the root directory and add your environment variables:
VITE_API_URL=https://dummyjson.com
Start the development server:
npm run dev
http://localhost:5173
.GET /api/products
- Retrieve all products.GET /api/products/:id
- Retrieve a single product by ID.POST /api/cart
- Add a product to the cart.DELETE /api/cart/:id
- Remove a product from the cart.VITE_API_URL
: The base URL for the API.