Skip to content

vasylpryimakdev/GameHub

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

64 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐ŸŽฎ Game Hub

A modern and responsive React application for discovering video games using the RAWG API.

Game Hub allows users to browse games, filter them by platform and release date, and explore detailed information in a clean and intuitive UI.


๐Ÿš€ Live Demo

๐Ÿ“ธ Screenshots

Homepage

Homepage

Game Detail Page

Game Detail Page


โœจ Features

  • ๐Ÿ” Search games
  • ๐ŸŽฎ Filter by platform
  • ๐Ÿ—‚ Filter by genre
  • ๐Ÿ“Š Sort games (rating, popularity, release date, etc.)
  • ๐Ÿ“œ Infinite scrolling
  • ๐ŸŒ™ Dark / Light mode
  • ๐ŸŽฅ Game trailers
  • ๐Ÿ–ผ Game screenshots
  • ๐Ÿ“„ Detailed game pages
  • โšก Fast data fetching with caching

๐Ÿ›  Tech Stack

Frontend

  • โš›๏ธ React
  • ๐Ÿ”ท TypeScript
  • โšก Vite

State & Data

  • ๐Ÿ”„ React Query (TanStack Query) โ€“ server state management
  • ๐Ÿป Zustand โ€“ global UI state

UI

  • ๐ŸŽจ Chakra UI
  • React Icons

Routing

  • React Router

API

  • RAWG Video Games Database API

Fetching

  • Axios

๐Ÿ“ธ Application Pages

Home Page

Browse games with filters and infinite scrolling.

Features:

  • platform filtering
  • genre filtering
  • sorting
  • search
  • infinite scroll

Game Detail Page

Displays detailed information about a selected game.

Includes:

  • game description
  • platforms
  • publishers
  • Metacritic score
  • screenshots
  • trailers

๐Ÿ“‚ Project Structure

src
โ”‚
โ”œโ”€โ”€ assets        # Images and static files
โ”œโ”€โ”€ components    # Reusable UI components
โ”œโ”€โ”€ data          # Static fallback data
โ”œโ”€โ”€ entities      # TypeScript interfaces
โ”œโ”€โ”€ hooks         # Custom React hooks
โ”œโ”€โ”€ pages         # Application pages
โ”œโ”€โ”€ services      # API logic
โ”œโ”€โ”€ store         # Zustand global store
โ”œโ”€โ”€ theme         # Chakra UI theme configuration
โ”‚
โ”œโ”€โ”€ main.tsx
โ””โ”€โ”€ routes.tsx

๐Ÿง  Key Concepts

React Query

Used for server state management:

  • data fetching
  • caching
  • background refetching
  • pagination
  • infinite scrolling

Zustand

Global state management for:

  • selected platform
  • selected genre
  • sorting
  • search query

API Client Abstraction

Reusable API client built with Axios that allows easy interaction with multiple endpoints.


๐ŸŽจ UI Features

  • Fully responsive layout
  • Dark mode support
  • Hover animations
  • Skeleton loading states
  • Grid layout with Chakra UI

โšก Performance Optimizations

  • React Query caching
  • Infinite scrolling
  • Skeleton loaders during data fetching
  • Image optimization using RAWG CDN

๐Ÿ“ฆ Installation

Clone the repository:

git clone https://github.com/vasylpryimakdev/GameHub.git
cd GameHub

Install dependencies:

npm install

Run the development server

npm run dev

The app will be available at

http://localhost:5173

๐Ÿ”‘ Environment Variables

Create a .env file in the root directory:

VITE_RAWG_API_KEY=your_api_key_here

Then update your axios instance:

params: {
key: import.meta.env.VITE_RAWG_API_KEY,
}

๐ŸŒ API

This project uses the RAWG Video Games Database API.

Documentation: https://rawg.io/apidocs

๐Ÿš€ Deployment

To deploy with Vercel:

npm i -g vercel
vercel

Or connect your GitHub repository directly through the Vercel dashboard.

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

GitHub: https://github.com/vasylpryimakdev LinkedIn: https://www.linkedin.com/in/vasyl-pryimak-64a204384

About

Game Hub - React TypeScript app for discovering video games via RAWG API. Features search, filters, infinite scroll, dark mode, and detailed game pages with trailers/screenshots. Built with React, Vite, Chakra UI, React Query, and Zustand.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages