This is a web application that displays a list of the top GitHub users and repositories based on different criteria, such as the number of followers, stars, or forks.
In the project directory, you can run:
- Clone the repository to your local machine.
- Install the dependencies using npm install.
- Rename the
.env.sample
file to.env.local
in the root directory and add your GitHub API token as REACT_APP_GITHUB_TOKEN=<your_token_here>. - Run the application using
npm start
. - Open the application in your browser at http://localhost:3000.
Launches the test runner in the interactive watch mode.
See the section about running tests for more information.
Builds the app for production to the build
folder.
It correctly bundles React in production mode and optimizes the build for the best performance.
The build is minified and the filenames include the hashes.
Your app is ready to be deployed!
-
api
To Communicate the application with an api
-
components
To reuse and organize better parts of the application
Folder pattern:
index.js - for exports Component.jsx - Component code style.css - Component style
-
layout
Functions as the shell of a project section
-
pages
Mains application pages
-
router
Used
react-router-dom
to make it, is responsible to create the navigation -
service
Maintain the company's rule, and it can use the API layer or other service
-
util
Utilities to be reused
-
Add model layer for User and Repository
User { username: String avatar: String email: String url: String followers: Number } Repository { name: String description: String url: String stars: Number }
-
Search functionality
-
Loading state for pages
-
Not found page
- Fix two requests per fetch