Giter VIP home page Giter VIP logo

github-repo-challenge's Introduction

GitHub Repo Search


React project, using GitHub API to search users and their repos


The following project is a small app that allows a user to make use of GitHub API and  search for Github members and their repositories. This app was developed as part of an interview process in which I have received this tech challenge. The main requirement of the project was for it to be written in TypeScript and, on a personal note I can share that  for me, this was the first time tackling TypeScript (ohh first starts, don’t we love them?), so a part of this README being informative about the “dull’ info, it is more of a documented post regarding some of the key concept I have learnt in the process.

 




Click for Demo

 Getting started


First things first! Make sure you create a .env file using the variable from .env.example (base url of GitHub API (https://api.github.com).

Then run npm command to install all dependencies needed and npm start to run the app on your local machine.

npm install


npm start


 

Developing

Technologies / Built With

Technologies and libraries used during app development include the following:

  • HTML5
  • CSS3
  • TypeScript
  • ReactTS
  • Styled Components
  • Prettier
  • esLint

App was built using create-react-app with typescript template  

Setting up Dev  

To test out the app, developers must clone the following repository:

git clone https://github.com/seficohen1/github-repo-challenge.git

cd project-folder/

npm install

Folder Structure

.
├── public                  # HTML entry point
├── src                     # Source files 
|   ├── components          # App components
│   ├── context             # Managing state with Context
│   ├── helpers             # Helper functions
│   ├── hooks               # Custom hooks
│   ├── interfaces          # Interfaces used in App
│   ├── pages               # Pages (also main components)
│   ├── services            # Connecting to GitHub API
│   ├── UI                  # Defining reusable styled components
|   ├── App.tsx             
|   ├── Index.tsx
|   ├── react-app-env.d.ts 
├── .env.example            # API BASE URL
├── .eslintrc               # esLint configuration file 
├── .prettierrc             # prettier configuration file 
├── tsconfig.json           # TypeScript compiler configuration 
└── README.md

Takeaways and Keypoints  

  • Understanding the fundamentals of TypeScript, what is it used for what problem it solves.  Sources I used to grasp my head around TypeScript concepts:     -  Ninja Net TypeScript tutorial - Free.     -  Codecademy Learn TypeScript Course - Free, the free version of the course does the job just fine with exercise and explanations     -  FrontendMasters - TypeScript Fundamentals - Paid course, I'm half way there, but learnt a lot from it.

  • Understanding how to use TypeScript around React environment, handling events and functions, managing state with context and reducer and understanding which react elements are passed as props. Sources I used a part of hours of googling:     - Fernando Herrera's React + TypeScript tutorial - Free and very much informative. Note: videos are  in Spanish


What's next?

  • Testing in TypeScript
  • Scaling to a bigger projects using state management libraries

Author

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.