This is a simple weather application built with HTML, CSS, and JavaScript. It allows users to check the current weather conditions based on their location or search for weather by entering the name of a city.
https://weathheraapp.netlify.app/
- View current weather conditions, including temperature, humidity, and wind speed.
- Get weather data for any city by entering its name.
- Responsive design, works on mobile and desktop devices.
- HTML: Provides the structure of the app.
- CSS: Styles the app and ensures it's responsive.
- JavaScript: Handles API requests to fetch weather data, dynamically updates the user interface, and processes user input.
- OpenWeatherMap API: Provides the weather data (free API key required).
To get started with this project, you can clone the repository:
git clone https://github.com/RaviSingh733/WeatherApp.git
cd WeatherApp
- Sign up on OpenWeatherMap and get your free API key.
- Once you have the key, replace YOUR_API_KEY in the script.js file with your actual API key:
- const apiKey = 'YOUR_API_KEY'; // Replace with your OpenWeatherMap API key
- After cloning the repo, open the index.html file in your browser.
- This will launch the weather app locally, and you can start searching for cities to view the weather.
- Alternatively, you can deploy the app on GitHub Pages (or another hosting platform) by following the instructions below.
- Push the project to your GitHub repository if you haven't already.
- Navigate to the repository settings.
- Scroll down to the "GitHub Pages" section.
- Under "Source", select the branch you want to deploy (usually main or master).
- After a few minutes, your weather app will be available at https://github.com/RaviSingh733/WeatherApp.git
- User Input: The user enters a city name into the input field.
- API Request: Upon submitting, the JavaScript fetch() function sends a request to the OpenWeatherMap API with the city name and the API key.
- Weather Data: The API returns the current weather data (e.g., temperature, humidity, wind speed), which is then displayed on the page.
- Error Handling: If the city is not found, the user will see an error message.
- This project is licensed under the MIT License - see the LICENSE file for details.
- OpenWeatherMap API for providing the weather data.
- FontAwesome for the icons used in the app.
- Project Title: The title of the project appears at the top.
- Live Demo: Optionally, you can provide a live link to the deployed app if you’ve published it on GitHub Pages or another hosting platform.
- Features: A brief overview of the app's functionality.
- Technologies Used: Highlights the key technologies involved in the project.
- Setup Instructions: Step-by-step guidance on how to set up the project locally, get an API key, and run the app.
- Deployment on GitHub Pages: Instructions on how to deploy the app using GitHub Pages.
- Folder Structure: A simple directory structure of the project to show the layout of the files.
- How the App Works: A description of the app's flow and functionality.
- Screenshots: Optional, but recommended for showcasing the look of the app.
- License: If you're sharing this as an open-source project, mention the license (MIT is a popular choice).
- Acknowledgments: Credits for any libraries, APIs, or tools you’ve used.
This format will help others easily understand your project, how to use it, and how to contribute or deploy it. Make sure to replace placeholder links like https://github.com/RaviSingh733/WeatherApp.git
with your actual URLs.