Skip to content

adiii637/Weather-App-JS

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1 Commit
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🌦️ Weather App β€” JavaScript (Async/Await + Fetch API)

The Weather App is a simple but powerful project built to strengthen JavaScript fundamentals such as API calling, async/await, DOM manipulation, error handling, and event handling. It allows users to search for any city and view real-time weather details fetched from a public weather API.

πŸš€ Features 🌀 1. Real-Time Weather Data

Displays temperature, humidity, wind speed, weather condition, etc.

Fetches live data from an external API.

⚑ 2. Fetch API + Async/Await

Fully asynchronous API calls.

Clean and modern JavaScript async code.

🧭 3. Search Any City

User enters a city name.

App shows weather instantly.

πŸ›‘ 4. Proper Error Handling

Invalid city β†’ shows an error message.

Handles network/API errors gracefully.

🎨 5. Beautiful UI

Clean layout with icons and background colors.

Fully responsive.

πŸ“ Folder Structure Weather-App/ β”‚ β”œβ”€β”€ css/ β”‚ └── style.css β”‚ β”œβ”€β”€ js/ β”‚ └── script.js β”‚ β”œβ”€β”€ images/ β”‚ └── weather icons β”‚ β”œβ”€β”€ index.html └── README.md

πŸ› οΈ Technologies Used

HTML5 β†’ UI Structure

CSS3 β†’ Styling & Responsive UI

JavaScript (Vanilla JS) β†’ Fetch API, async/await, DOM updates

OpenWeather / Any Weather API

πŸ“Œ What This Project Demonstrates (Important for Resume)

This project strengthened my JavaScript fundamentals, including:

βœ” Async/Await βœ” Promises & Fetch API βœ” API Integration βœ” Handling JSON Response βœ” DOM Manipulation βœ” Event Handling βœ” Error Handling

This is why Weather App is considered one of the best beginner JavaScript projects β€” it touches almost all core concepts of JS used in real-world apps.

βš™οΈ How to Use

Clone the repository:

git clone https://github.com/your-username/weather-app.git

Open the folder:

cd weather-app

Start the app:

Simply open index.html in any browser or

Use VS Code β†’ Open with Live Server

Enter your API key inside script.js:

const apiKey = "YOUR_API_KEY";

πŸ–₯️ Working

User enters a city name.

JavaScript calls the weather API using fetch() and async/await.

API sends a JSON response.

App extracts:

Temperature

Weather description

Wind speed

Humidity

Icon

All data is inserted into the DOM dynamically.

πŸ“Έ Screenshot

Here is how the Weather App looks:

Screenshot

πŸ”₯ Future Enhancements

Add a 5-day weather forecast

Add geo-location weather (auto detect current city)

Add dark/light mode

Save previous searches

About

🌦️ Weather App β€” JavaScript (Async/Await + Fetch API) The Weather App is a simple but powerful project built to strengthen JavaScript fundamentals such as API calling, async/await, DOM manipulation, error handling, and event handling.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors