A native iOS weather app, providing current weather and 6 days forecasts. It supports both geolocation-based weather fetching and manual city input. The app ensures smooth user experience through interactive animations and day/night-themed colors, following the MVVM architecture with no third-party dependencies.
-
Weather for Current Location
- If the user grants location permission, the app fetches weather data for the current city.
- By pressing gps floating button will fetch current location weather details.
-
Manual City Input
- If permission is denied or unavailable, the user can manually search for a city and view weather details.
-
Weather Forecast
- Provides 2-3 day forecasts for the selected location.
-
Interactive Animations & Themes
- Displays weather-based animations for conditions like rain.
- Day and night themes based on the selected location’s time.
-
Error Handling
- Handles invalid city names gracefully with user-friendly messages.
- Displays a "No Internet" message if there is no network connection.
-
Minimal Dependency
- No third-party libraries used; the project leverages UIKit and native APIs for all functionalities.
Preview 1 | Preview 2 | Preview 3 | Preview 4 |
---|---|---|---|
- Current Temperature
- Minimum and Maximum Temperature
- Pressure
- Visibility
- Humidity
- Weather Overview
- Date and Time
- Weather Icons (if available)
The app follows the MVVM (Model-View-ViewModel) architecture, ensuring:
- Clear separation between UI and business logic.
- Maintainable and scalable code.
- Easier testing and future enhancements.
-
Clone the Repository
git clone https://github.com/your-username/weather-app.git cd weather-app
-
Open in Xcode
Open the.xcodeproj
file in Xcode.
Make sure you have Xcode 13+ installed. -
Run the App
Connect a simulator or device, and hit Run (Cmd + R
). -
Grant Location Permissions
The app will request location permission to display the weather for the current location. If denied, you can manually search for city weather.
-
Location Permission Denied
Displays an error message, but the user can still search manually for weather information. -
No Internet Connection
Shows a "No Internet" message if the network is unavailable. -
Invalid City Name
Displays a "City not found" message when the input city is unrecognized.
This project is licensed under the MIT License. See the LICENSE file for details.
For any questions, feedback, or suggestions, please reach out to me at:
- Email: [email protected]
- LinkedIn: Kishan Barmawala
Your thoughts are greatly appreciated!