This project was tied in with working with Web APIs and offbeat code, making a web application that utilizes OpenWeatherMap API to get climate dependent on the client's area, and progressively update UI.
This will require modifying the server.js
file and the website/app.js
file. You can see index.html
for element references, and once you are finished with the project steps, you can use style.css
to style your application to customized perfection.
To get the project up and running I followed these steps:
Setting up project environment, making sure I have Node and packages installed, and included in my server.js file. Added POST and GET routes to ensure correct retrieval of data from the server. Acquired API credentials from OpenWeatherMap website. Created async functions to fetch weather data and store it on my local server. Set up a function that updated UI dynamically. Result
If you are interested in testing your code as you go, you can use tests.js
as a template for writing and running some basic tests for your code.