This repositority is a tutorial for using https://api.met.no/weatherapi/locationforecast/2.0/documentation to present a weather forecast on a web page.
The components of this application are:
- Forecast from api.met.no: A web service that gives you a 10-day forecast for any location on earth.
- Nginx: A proxy and a web server for static files.
- Web page: The forecast web page is made with css from https://milligram.io/ and some html and javascript.
A diagram of the tutorial application looks like this:
The forecast returned from api.met.no is encoded in json. If json is unfamiliar to you, you can learn about it here.
The web page is built with html and javascript. If you are unfamiliar with javascript, you can find various javascript guides here.
Each step in the tutorial is placed in its own file, so you if want to do the tutorial over multiple sessions, you can go directly to the step where you left off.
When you run into a code block, please type in the code, instead of copy-and-paste. That way, its easier to learn what is going on.
The tutorial is written for Windows 10 users, so paths and commands will have to be changed if you are using a different operating system.
The tutorial is meant to be done in the following order: