A simple iOS app built with SwiftUI that allows users to compare the weather of two cities side by side. It fetches real-time weather data from the OpenWeatherMap API and displays the temperature, weather condition, and icons for selected cities.
โ
Select two cities from a list
โ
Fetch real-time weather data using OpenWeatherMap API
โ
Display temperature, weather description, and icons
โ
SwiftUI-based responsive design
โ
Uses URLSession for API requests
- Swift 5 & SwiftUI
- Xcode
- OpenWeatherMap API
- URLSession for Networking
- JSON Parsing
- Install Xcode (latest version) from the Mac App Store
- Get an API key from OpenWeatherMap
- Clone the repository:
git clone https://github.com/YOUR_USERNAME/WeatherCompare.git cd WeatherCompare - Open WeatherCompare.xcodeproj in Xcode.
- Replace "YOUR_API_KEY" in ContentView.swift with your actual API key.
- Select an iPhone simulator and Run the project (Cmd + R).
