A simple and intuitive Weather App built using SwiftUI for iOS. This app allows users to get real-time weather information based on their location or a manually entered city name.
- Real-time weather data: Fetches current weather conditions using a third-party API (e.g., OpenWeatherMap).
- Location-based weather: Automatically detects the user's location and displays the weather for that location.
- Search functionality: Users can manually search for weather by entering a city name.
- Clear UI: Built using SwiftUI for a modern, clean, and responsive user interface.
- Dark mode: Supports iOS's Dark Mode for a comfortable viewing experience in all lighting conditions.
- iOS 15.0+
- Xcode 12.0+
- Swift 5.3+
- An API key from OpenWeatherMap or another weather data provider.
-
Clone the Repository
Clone this repository to your local machine:git clone https://github.com/your-username/SwiftUI-Weather-App.git
-
Open the Project in Xcode Navigate to the project folder and open the .xcodeproj file in Xcode.
-
Get an API Key To fetch weather data, you need an API key from OpenWeatherMap or any other weather API provider: Go to OpenWeatherMap and sign up for an account. Copy your API key after registering.
-
Set Your API Key in the App Open the WeatherApp.swift or relevant configuration file in the project and replace the placeholder API key with your actual key.
-
Run the App Select a simulator or connect a device, and then build and run the app.