A Flutter application for checking weather forecasts and air quality index (AQI) using the OpenWeatherMap API.
- Overview
- Features
- Libraries Used
- APIs Used
- Setup Instructions
- Usage
- Screenshots
- Contributing
- License
The Weather App is a mobile application developed in Flutter that allows users to retrieve current weather conditions, view weather forecasts, and check air quality index (AQI) for any location around the globe. It leverages the OpenWeatherMap API to fetch weather data and geolocation services for obtaining user coordinates.
- Current Weather: Display current temperature, weather conditions, humidity, wind speed, and more for a specified location.
- Weather Forecast: Show weather forecasts for the next few days, including temperature highs/lows and weather icons.
- Air Quality Index (AQI): Retrieve and display AQI data based on geographical coordinates.
- shimmer_animation: Provides shimmering effect animations while data is loading. 🌟
- intl: Internationalization and localization support for multi-language app versions. 🌍
- provider: State management for efficient data flow within the app. 🔄
- http: HTTP requests for seamless communication with the OpenWeatherMap API. 📡
- geolocator: Fetches device location coordinates for accurate weather data retrieval. 📍
- geocoding: Converts between geographical coordinates and place names for user-friendly location search. 🔍
- flutter_easyloading: Displays loading indicators during data fetching processes. ⏳
- google_fonts: Integrates custom fonts for enhanced visual appeal and readability. 🎨
- shimmer: Implements shimmer effects for smooth loading placeholders. ✨
- carousel_slider: Provides a carousel widget for interactive weather forecast display. 🎠
- flutter_screenutil: Offers adaptive screen size management for consistent UI across devices. 📱
- OpenWeatherMap API:
- Current Weather: Retrieves real-time weather data such as temperature, humidity, wind speed, and weather conditions. 🌡️💧💨
- Weather Forecast: Fetches weather forecast data for upcoming days, including temperature highs/lows and weather icons. 🌤️🌧️❄️
- Air Quality Index (AQI): Gets AQI data based on latitude and longitude coordinates. 🌍🌱
- Clone the repository: git clone https://github.com/your/repository.git cd repository_name
- Add your API key:
- Obtain an API key from OpenWeatherMap.
- Create a file named
api.dart
inlib/utils/
directory. - Add your API key in
api.dart
:const String apiKey = 'YOUR_API_KEY';
- Install dependencies:
- Run the app:
- Upon launching the app, the location permission dialog opens up.
- By giving access to location permission, the current weather for your current location will be displayed.
- Swipe through forecast cards to view AQI Details and Guidlines.
Loading Screen
Weather Data Loaded
*Weather AQI
The app design and icons are inspired by a Figma design file created by Pasindu (Weather App (Community)). We thank them for their creative contribution.
Contributions are welcome! If you find any issues or have suggestions for improvement, please submit an issue or a pull request.
This project is licensed under the MIT License - see the LICENSE file for details.