Asynchronous JavaScript Project

Explore current weather with callbacks and API requests.

A clean front-end application that retrieves weather information, manages loading and error states, and renders results dynamically in the browser.

Get current weather

Use demo mode for portfolio preview, or paste your own OpenWeather API key for live API data.

The key is stored only in your browser's localStorage. It is not included in the repository.

Ready to search

Idle
Enter a city and click “Get Weather” to display current conditions.
Temperature
Feels like
Humidity
Wind

What this project demonstrates

This project turns a basic callback exercise into a portfolio-ready application with stronger UX, safer API-key handling, and clearer code organization.

Callback functions

Passes a display function into the data-fetching workflow and runs it once weather data is available.

Fetch API

Uses asynchronous requests to retrieve current weather data from OpenWeather when API mode is enabled.

Error handling

Handles missing input, failed requests, invalid cities, and missing API keys with user-friendly messages.

DOM rendering

Updates the interface dynamically with temperature, humidity, wind speed, and status indicators.