The project is build using REST API
This command clones the repo and installs all dependencies required to run the application.
Also, it will generate package-lock.json
.
git clone https://github.com/aggarwal-muskaan/restCountriesAPI.git/
cd [foldername]
npm install && npm start
There are total 3 endpoints:
- pulls data of all countries
- pulls data matches with country name
- pulls data based on Region.
The global state is initialized with the data of all countries when the app runs for the first time.
The country is searched in that instance if user searched from the URL.
desktop-design-home-light | desktop-design-detail-dark | mobile-design-detail-light |
Click here to see app in action.
- See all countries on the homepage
- Search for a country using an input field
- Filter countries by region
- Click on a country to see more detailed information
- Click through to the border countries on the detail page
- Toggle the color scheme between light and dark mode
- PropTypes : for typechecking
- Styled Components : for styling (you will definitely fall in love)
- Debouncing : hits API after a gap of given time & not call API after every change made by user
- Lazy Loading : code-splitting with dynamic imports (improve performance of apps using large third-party libraries)
- Unit Testing : makes debugging easy if we write more tests before code. (P.S- I've not used TDD)
==> Learn Redux <==