Skip to content

im-manideep/Weather-app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

Here's the complete README.md content - copy and paste it! 📄


# 🌦️ Weather App

A beautiful and responsive weather application that provides real-time weather information for any city in the world.

![Weather App Preview](https://img.shields.io/badge/Status-Active-success) ![HTML5](https://img.shields.io/badge/HTML5-E34F26?logo=html5&logoColor=white) ![CSS3](https://img.shields.io/badge/CSS3-1572B6?logo=css3&logoColor=white) ![JavaScript](https://img.shields.io/badge/JavaScript-F7DF1E?logo=javascript&logoColor=black)

## ✨ Features

- 🔍 **Real-time Search** - Search weather by city name
- 🌡️ **Temperature Display** - Shows current temperature in Celsius
- 💧 **Humidity Level** - Displays current humidity percentage
- 💨 **Wind Speed** - Shows wind speed in km/h
- 🎨 **Dynamic Weather Icons** - Icons change based on weather conditions (Clouds, Clear, Rain, Drizzle, Mist)
- 📱 **Responsive Design** - Beautiful gradient UI that works on all devices

## 🚀 Demo

[Live Demo](https://karnemanideep.github.io/Weather-app/)

## 🛠️ Technologies Used

- **HTML5** - Structure
- **CSS3** - Styling with modern gradients and flexbox
- **JavaScript (ES6+)** - Async/await for API calls
- **OpenWeatherMap API** - Weather data provider

## 📋 Prerequisites

Before you begin, you'll need:
- A modern web browser (Chrome, Firefox, Safari, Edge)
- OpenWeatherMap API key (free tier available)

## ⚙️ Installation & Setup

1. **Clone the repository**
```bash
git clone https://github.com/karnemanideep/Weather-app.git
cd Weather-app
  1. Get your API Key

    • Visit OpenWeatherMap
    • Sign up for a free account
    • Generate your API key
  2. Add your API key

    • Open index.html
    • Replace the API key on line 42:
    const apiKey = "YOUR_API_KEY_HERE";
  3. Run the app

    • Simply open index.html in your browser
    • Or use a local server:
    python -m http.server 8000
  4. Access the app

    • Navigate to http://localhost:8000 in your browser

📁 Project Structure

Weather-app/
│
├── WEATHER APP/
│   ├── images/
│   │   ├── search.png
│   │   ├── rain.png
│   │   ├── clouds.png
│   │   ├── clear.png
│   │   ├── drizzle.png
│   │   ├── mist.png
│   │   ├── humidity.png
│   │   └── wind.png
│   │
│   ├── index.html
│   ├── style.css
│   └── app.js
│
└── README.md

🎯 How It Works

  1. User Input - Enter a city name in the search box
  2. API Call - App fetches weather data from OpenWeatherMap API
  3. Data Processing - JavaScript processes the JSON response
  4. Dynamic Update - UI updates with city name, temperature, humidity, wind speed, and weather icon

🎨 Weather Conditions Supported

  • ☁️ Clouds
  • ☀️ Clear sky
  • 🌧️ Rain
  • 🌦️ Drizzle
  • 🌫️ Mist

🔧 Customization

Change Temperature Units

Modify the API URL to use Fahrenheit:

const apiUrl = "https://api.openweathermap.org/data/2.5/weather?units=imperial&q=";

Change Color Scheme

Edit style.css:

.card {
    background: linear-gradient(135deg, #YOUR_COLOR_1, #YOUR_COLOR_2);
}

🚀 Future Improvements

  • Add error handling for invalid city names
  • Add loading spinner during API calls
  • Implement 5-day forecast
  • Add geolocation support
  • Store recent searches in localStorage
  • Add dark mode toggle

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

👨‍💻 Author

Manideep Karne

🙏 Acknowledgments


Star this repo if you found it helpful!


---

Copy ALL of this and paste it into the GitHub README editor! 🚀

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors