In most cases of personal projects, it is very common to pull basic data from an external API. This is what we have accomplished so far in this nanodegree. However, many production-level applications do not rely on only a single source of data, they usually pull multiple data from various resources and make them available to different parts of the app asynchronously, so one API can use the data gathered from another API.
-
Geonames API - Geographical database from which the location data is pulled
-
WeatherBit API - Weather API for current and future weather data
-
Pixabay API - RESTful interface for searching and retrieving free images and videos
-
Country API - RESTful Api for countries names and details
- Setup Webpack Development Enviroment: For this, I have created a gist to follow along.
- Setup a form where users can enter the trip destination and the dates
- Pull data including lattitude, longtitude and country code from Geonames API using user input
- Pass this data to Weatther API along with user entered dates to obtain weather information
- Introduce a countdown to find out how many days to the trip
- Use country code to pull country name and national flag usin REST Countries API
- Use location and country name to pull images from Pixabay API
-
Download or clone the project:
-
Install dependencies
npm install
- Start the server
npm start
- Setup the environment development or production
npm run build-dev
- or
npm run build
- Test with Jest
npm run test
-
You need first to rename the file located at
src/server/config
fromconfig.env.env
->config.env
-
Then you need to replace the sample API keys with real once
- Bootstrap - The CSS framework used
- Sass - The web framework used
- Webpack - Asset Management
- Babel - JavaScript Compiler
- Node.js - JavaScript Runtime
- Express.js - Server Framework for Node.js
- Jest - Testing suit
- Service Workers - For offline capability
To test the application, run
npm run test
This project already has been hosted using heroku at : https://travel--plus.herokuapp.com