Skip to content

Latest commit

ย 

History

17 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ›๏ธ JHAY HUB โ€“ React E-commerce Application

React Vite Tailwind CSS License

A modern, responsive e-commerce web application built with React 19, Vite, and Tailwind CSS.

JHAY HUB uses the Fake Store API to retrieve product data and provide a realistic online shopping experience while demonstrating modern React development practices.

The project was built to strengthen my understanding of React fundamentals, reusable component architecture, state management, routing, API integration, responsive design, UI/UX principles, and frontend best practices.


๐ŸŒ Live Demo

๐Ÿ”— Live Preview: JHAY HUB

๐Ÿ”— GitHub Repository: JhayCodesDev/react-ecommerce-jhayhub


โœจ Features

  • ๐Ÿ›’ Browse available products
  • ๐Ÿ” Search for products
  • ๐Ÿ“‚ Browse products by category
  • ๐Ÿ“„ View detailed product information
  • ๐Ÿ›๏ธ Add products to the shopping cart
  • โž• Increase and decrease cart quantities
  • ๐Ÿ—‘๏ธ Remove products from the cart
  • ๐Ÿ’พ Persist cart data using Local Storage
  • ๐ŸŒ™ Dark and Light mode
  • ๐Ÿ“ฑ Fully responsive design
  • ๐Ÿ“ฑ Responsive mobile navigation
  • ๐Ÿ”” Toast notifications
  • โฌ†๏ธ Back-to-top button
  • โšก Custom loading state
  • โš ๏ธ Custom API and network error handling
  • ๐Ÿšซ Custom 404 Not Found page
  • ๐ŸŽจ Custom category images
  • ๐Ÿ–ผ๏ธ Custom favicon
  • ๐Ÿ”Ž Basic SEO optimization
  • ๐Ÿงฉ Reusable React components
  • ๐ŸŽจ Custom design system and CSS utilities

๐ŸŽจ UI/UX Design Process

The JHAY HUB interface was refined through a combination of custom development, responsive testing, and UI analysis.

Google Stitch was used as a UI analysis and design reference tool to explore possible improvements to the application's interface and user experience.

The final implementation was developed and customized manually in React and Tailwind CSS, with a focus on:

  • Clear visual hierarchy
  • Responsive layouts
  • Consistent spacing and typography
  • Reusable design tokens
  • Light and Dark themes
  • Accessible navigation
  • Consistent interactive states
  • Mobile usability
  • Practical and maintainable component architecture

The goal was to use UI analysis as a reference while maintaining full control over the application's implementation and codebase.


๐Ÿ› ๏ธ Technologies Used

  • React 19 โ€“ UI development
  • Vite 7 โ€“ Development environment and build tool
  • JavaScript (ES6+) โ€“ Application logic
  • Tailwind CSS 4 โ€“ Styling and responsive design
  • React Router โ€“ Client-side routing
  • React Icons โ€“ Icon library
  • React Hook Form โ€“ Form handling
  • React Toastify โ€“ Toast notifications
  • Context API โ€“ Global state management
  • Fake Store API โ€“ Product data
  • Prettier โ€“ Code formatting
  • Google Stitch โ€“ UI/UX analysis and design reference
  • Vercel โ€“ Deployment

๐Ÿ“ Project Structure

react-ecommerce-jhayhub/
โ”‚
โ”œโ”€โ”€ public/
โ”‚   โ”œโ”€โ”€ 404-page.png
โ”‚   โ”œโ”€โ”€ cart.png
โ”‚   โ”œโ”€โ”€ dark-mode.png
โ”‚   โ”œโ”€โ”€ home.png
โ”‚   โ”œโ”€โ”€ light-mode.png
โ”‚   โ”œโ”€โ”€ mobile-navigation.png
โ”‚   โ”œโ”€โ”€ product-details.png
โ”‚   โ””โ”€โ”€ shop.png
โ”‚
โ”œโ”€โ”€ src/
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ assets/
โ”‚   โ”‚   โ””โ”€โ”€ ...
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ components/
โ”‚   โ”‚   โ”œโ”€โ”€ About.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ CategoryCard.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ ErrorMessage.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ Footer.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ Hero.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ Loading.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ Login.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ NavBar.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ ProductCard.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ ScrollToTop.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ SearchBar.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ SignUp.jsx
โ”‚   โ”‚   โ””โ”€โ”€ ...
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ context/
โ”‚   โ”‚   โ”œโ”€โ”€ AuthContext.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ CartContext.jsx
โ”‚   โ”‚   โ””โ”€โ”€ ThemeContext.jsx
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ Pages/
โ”‚   โ”‚   โ”œโ”€โ”€ Cart.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ Electronics.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ FeaturedProduct.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ Home.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ Jewelry.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ Mens.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ NotFound.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ ProductDetails.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ Shop.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ WhyChooseUs.jsx
โ”‚   โ”‚   โ””โ”€โ”€ Womens.jsx
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ App.jsx
โ”‚   โ”œโ”€โ”€ main.jsx
โ”‚   โ””โ”€โ”€ index.css
|
โ”œโ”€โ”€ package.json
โ”œโ”€โ”€ vite.config.js
โ”œโ”€โ”€ README.md
โ””โ”€โ”€ ...

๐Ÿ“ธ Screenshots

๐Ÿ  Home Page

Home Page


๐Ÿ›๏ธ Shop Page

Shop Page


๐Ÿ“„ Product Details

Product Details


๐Ÿ›’ Shopping Cart

Shopping Cart


๐ŸŒ™ Dark Mode

Dark Mode


โ˜€๏ธ Light Mode

Light Mode


๐Ÿ“ฑ Mobile Navigation

Mobile Navigation


๐Ÿšซ 404 Not Found Page

404 Page


โš™๏ธ Installation

1. Clone the repository

git clone https://github.com/JhayCodesDev/react-ecommerce-jhayhub.git

2. Navigate into the project

cd react-ecommerce-jhayhub

3. Install dependencies

npm install

4. Start the development server

npm run dev

The application will be available at the local development URL provided by Vite.


๐Ÿ“ฆ API

JHAY HUB uses the Fake Store API to retrieve product information.

API Endpoint:

https://fakestoreapi.com/products

The application fetches product data from the API and uses it to populate product listings, categories, search results, and product detail pages.

API Error Handling

Because the application depends on an external API, JHAY HUB includes custom error handling for situations such as:

  • API request failures
  • Network connectivity problems
  • Unexpected API responses
  • Empty or unavailable product data

When a connection problem occurs, users receive a custom error message prompting them to refresh the page or check their network connection.


๐Ÿง  What I Learned

Building and refining JHAY HUB strengthened my understanding of:

  • React component architecture
  • Reusable component design
  • State management with Context API
  • React Hooks such as useState, useEffect, and useContext
  • React Router navigation
  • Fetching and displaying API data
  • Conditional rendering
  • Search and filtering logic
  • Responsive UI development
  • Dark and Light theme implementation
  • Local Storage
  • Loading and error states
  • Custom API and network error handling
  • Toast notifications
  • Mobile navigation
  • Accessible navigation
  • UI/UX analysis and implementation
  • Maintaining a scalable React application

๐Ÿ”ฎ Future Improvements

Planned enhancements include:

  • Offline fallback using local JSON data when the Fake Store API is unavailable
  • Persist fetched products in Local Storage to reduce unnecessary API requests
  • Product sorting by price, popularity, and newest
  • Wishlist functionality
  • Backend-based user authentication
  • Checkout and payment integration
  • Product reviews and ratings
  • Pagination and lazy loading
  • Further performance optimization
  • Unit and integration testing

๐Ÿ‘จโ€๐Ÿ’ป Developer

Developed by JhayCodes

JHAY HUB is part of my journey toward becoming a skilled software developer through building practical, production-style applications.

The project focuses on clean architecture, maintainable code, responsive design, reusable components, and a strong user experience.

Connect with Me


๐Ÿ“„ License

This project is licensed under the MIT License.


โญ If you found this project interesting, feel free to explore the repository and follow my development journey.

About

Modern React e-commerce application featuring product search, category filtering, shopping cart, dark/light mode, and responsive design.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages