This Android Application provides users with real-time weather information based on their current location. And also get information for some listed cities. This app is designed with a clean user interface, making it easy for users to check the weather conditions quickly. It utilizes modern Android development components such as MVVM, Room Database, Retrofit2 and Lottie animation
Features
- Current Weather: Get real-time weather information including temperature, humidity, wind speed, wind direction, air pressure, sun rise and set.
- Weather By City: Get weather information for some listed cities
- Location-Based Updates: Automatically fetch GPS weather data for the user's current location.
- User-friendly UI: Clean and modern design with navigation.
- Dark Mode: Support dark mode for better usability in low-light conditions.
- Theme Handling: By default system theme will apply, and the user can switch to a light, dark or system-based theme.
- Offline access: Save weather data locally using Room Db for offline access.
- Smooth Animation: Enhanced user experience with Lottie animation
Architecture This app is built using MVVM(Model-View-ViewModel) architecture to ensure a clear separation of concerns and to make the code more maintainable
Technologies Used MVVM Architecture - Ensure a clean separation between the UI and business logic Room Db - Provides local data storage for offline access Retrofit - Handles network request to fetch weather data from the API Lottie Animation - Add smooth and visually appealing animations to the app Coil - Image loading library
Download APK Install weather_app.apk in your android device
Installation To get a local copy up and running follow these steps.
Prerequisites:
- Android Studio (this is developed in Android Studio Koala)
- Android SDK
- Java JDK
Clone the Repository git clone https://github.com/Razin1993/weather-app.git
Open in Android Studio
- Open Android Studio
- Click on File -> Open
- Navigate to the cloned repository and click ok
Build and Run In this app, Used OpenWeatherMap API to get weather info. It requires an API key. So add your API_KEY in local.properties
- Add API_KEY and BASE_URL in local.properties
- Make sure you have an Android device or emulator
- Click on Run-> Run app
Usage
- Launch the APP: Open the Weather app on your Android device.
- Allow location access: When location permission is prompted, allow the app to access your location to fetch weather data for your current location.
- View Weather info: The home screen will display the current weather and forecast.
- Other cities: The user can able to see the weather info for some listed cities in the app.