Simple Weather app created with HTML, CSS, and JavaScript using the APIs for fetching weather and geolocation information - Take a look
- HTML
- CSS
- Vanilla JS - ES6
- Awesomeness - Strictly for the love of coding :-)
fetchWeather: function (city) {
fetch(
"https://api.openweathermap.org/data/2.5/weather?q=" +
city +
"&units=metric&appid=" +
this.apiKey
)
.then((response) => {
if (!response.ok) {
alert("No weather found.");
throw new Error("No weather found.");
}
return response.json();
})
.then((data) => this.displayWeather(data));
},
- Open Weather API
- Unsplash API
- Download Code or Clone the repository
git clone https://github.com/KaranChandekar/weather-app.git
- Go to the directory
- Run the index.html file
- Just Type the city name you want to know the weather of, and then click on the search button.
- After that it will automatically display Weather, Humidity, Wind Speed of the enered city.
Weather.App.mp4
Contributions are highly welcome. Feel free to fork, clone, make pull requests, report issues etc.
- Anyone who is reading this... You're awesome!
That being said
To the Front... to the Back... End to End... cut no slack. Making ends meet. lol