A React-Typescript application that allows users to filter through a list of PC/Web Browser based games provided by freetogame.com/api-doc.
I made this application as a side-project to help solidify my knowledge of React and Typescript, as I know I will be using them both in conjunction with one-another for many years to come post graduation.
Project Setup
-
Utilized
Babelandcore-jsto transpile the code to ECMAScript 6. -
Utilized
ESLintandPrettierto enforce code quality. -
Utilized
Webpackto bundle the code into a single file. -
Utilized
yarnas my package manager instead ofnpmfor my first time (ps, i loved it!)
Project Development
-
Utilized
Reactto create the front-end of the application. -
Implemented Responsive Design using
styled-componentsat these custom breakpoints:
export const breakpoints = {
tablet: '720px',
desktop: '1024px',
}-
Utilized
axiosto create myuseFetchhook to pull data from the API. -
Filters:
- Platform
- Browser (Web)
- Windows (PC)
- Genre
- MMO
- MMORPG
- Shooter
- Strategy
- Moba
- Card Games
- Racing
- Sports
- Social
- Fighting
- Sort By:
- Relevance
- Popularity
- Release Date
- Alphabetical
- Platform
-
Utilized
Styled-Componentsto style the application. -
Implemented
HOCto handlegetDerivedStateFromErrorandcomponentDidCatchfor error handling. -
Utilized
React-Routerto handle the routing of the application (even though this is a single page application).
| Library/Framework | Version |
|---|---|
| @babel/polyfill | ^7.12.1 |
| axios | ^0.26.1 |
| core-js | ^3.21.1 |
| react | ^18.0.0 |
| react-dom | ^18.0.0 |
| react-router-dom | 5.2.0 |
| styled-components | ^5.3.5 |
| Library/Framework | Version |
|---|---|
| @babel/core | ^7.17.9 |
| @babel/preset-env | ^7.16.11 |
| @babel/preset-react | ^7.16.7 |
| @babel/preset-typescript | ^7.16.7 |
| @types/axios | ^0.14.0 |
| @types/react | ^18.0.1 |
| @types/react-dom | ^18.0.0 |
| @types/react-router-dom | ^5.3.3 |
| @types/styled-components | ^5.1.25 |
| @typescript-eslint/eslint-plugin | ^5.18.0 |
| @typescript-eslint/parser | ^5.18.0 |
| babel-loader | ^8.2.4 |
| babel-plugin-styled-components | ^2.0.7 |
| eslint | ^8.13.0 |
| eslint-config-prettier | ^8.5.0 |
| eslint-plugin-react | ^7.29.4 |
| eslint-plugin-react-hooks | ^4.4.0 |
| gh-pages | ^3.2.3 |
| html-webpack-plugin | ^5.5.0 |
| prettier | ^2.6.2 |
| typescript | ^4.6.3 |
| webpack | ^5.72.0 |
| webpack-cli | ^4.9.2 |
| webpack-dev-server | ^4.8.1 |