Skip to content

Mahesh20dev/Weather-App

Repository files navigation

Weather App

This is a simple weather app that displays the current weather conditions based on the user's location or a selected city. The app uses the OpenWeatherMap API to fetch weather data.

Features

  1. Display the current temperature, weather description, and location.
  2. Toggle between Celsius and Fahrenheit for temperature units.
  3. Allow the user to search for weather conditions in a specific city.
  4. Display an icon representing the current weather condition.

Instructions

  1. Open the index.html file in a web browser.
  2. Allow the browser to access your location if you want to see the weather based on your current location.
  3. Enter a city name in the input field and click the "Get Weather" button to see the weather conditions for that city.
  4. Click the "Current Location Weather" button to see the weather conditions based on your current location.
  5. Click on the temperature value to toggle between Celsius and Fahrenheit.

Additional Libraries and Tools

  1. Skycons: A lightweight JavaScript library for displaying weather icons.
  2. Font Awesome: A popular icon font library for displaying icons.

Notes

  1. The app uses the OpenWeatherMap API, which requires an API key. You can sign up for a free API key at https://openweathermap.org/api.
  2. The app uses the Geolocation API to get the user's location. Make sure to allow the browser to access your location if prompted.
  3. The app uses the Fetch API to make HTTP requests to the OpenWeatherMap API.
  4. The app uses CSS Flexbox for layout and styling.
  5. The app uses JavaScript to handle user interactions and update the weather information on the page.
  6. If you get any error in temparature readings , "refresh the window".

About

Weather App

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published