A simple and elegant weather application which allows users to check the current weather details by entering the name of a city.
Access the application here: https://myweathercheck.netlify.app/
- City-based Weather Search: Enter the name of a city to fetch weather details.
- Current Weather Details: Displays temperature and weather conditions (e.g., sunny, cloudy, rainy).
- Additional Information: Shows the country name, region name, and local time for the entered city.
- Input Validation: Ensures the entered city name is valid.
- HTML: Structure and layout of the app.
- CSS: Styling for a clean and user-friendly interface.
- JavaScript: Core functionality to fetch and display weather details dynamically.
- The user enters a city name in the input field.
- The app validates the input.
- A weather API is called to fetch real-time weather data for the entered city.
- If the city name is valid, the app displays:
- Temperature
- Weather conditions (e.g., sunny, rainy)
- Country name
- Region name
- Local time
- If the city name is invalid, an error message is displayed.
Showing weather for Cupertino, California
Error message is diplayed below upon looking for an invalid city name
-
Clone the repository:
git clone https://github.com/LeadGeekSquad/WeatherCheck
-
Navigate to the project directory:
cd WeatherCheck -
Open
weather.htmlin your preferred web browser.
- Weather API: The app uses a weather API to fetch the data. Make sure to replace
YOUR_API_KEYin the JavaScript file with your actual API key.
weather-app/
├── weather.html # Main HTML file
├── weather.css # CSS file for styling
├── weather.js # JavaScript file for functionality
└── README.md # Documentation (this file)
- Open the app in a browser.
- Enter the name of a city in the input field and press the get weather button.
- View the weather details, including temperature, weather conditions, country name, region name, and local time.
- For invalid city names, an error message will guide you to correct the input.
Contributions are welcome! Feel free to contribute to this project by submitting issues or pull requests. Your feedback and ideas are greatly appreciated! If you'd like to improve this app or add features, follow these steps:
-
Fork the repository. Link to the repository.
-
Create a new branch:
git checkout -b feature-name
-
Commit your changes:
git commit -m "Add your message here" -
Push to the branch:
git push origin feature-name
-
Open a pull request.


