Skip to content

CodeWithKhan07/weatherly

Repository files navigation

Weatherly 🌤️

A beautiful, feature-rich Flutter weather application built with Clean Architecture and BLoC state management. Weatherly provides real-time weather forecasts with an elegant glassmorphism UI, supporting multiple saved locations and detailed hourly/weekly forecasts — all powered by the free Open-Meteo API (no API key required).


📸 Screenshots

Splash Screen Add Location Saved Locations Current Weather Hourly Weather

Weekly Weather Settings


✨ Features

  • 🌡️ Current Weather — Temperature, feels-like, humidity, wind speed, UV index, and more
  • 📅 Weekly Forecast — 7-day daily forecast with min/max temperatures and conditions
  • ⏱️ Hourly Forecast — Hour-by-hour breakdown with animated weather indicators
  • 📍 Location Management — Search cities worldwide, detect GPS location, save multiple locations
  • 🔔 Notifications — Daily weather notifications via Awesome Notifications
  • ⚙️ Settings — Toggle notifications, manage preferences
  • 🎨 Glassmorphism UI — Stunning frosted-glass cards with smooth animations
  • 🌙 Offline-first — Cached weather data via Hive for offline access

🏗️ Architecture

Weatherly follows Clean Architecture principles with three distinct layers:

lib/
├── core/                         # Shared infrastructure
│   ├── constants/                # App-wide constants
│   ├── dependency_injection/     # GetIt service locator setup
│   ├── exceptions/               # Custom exception types
│   ├── network/                  # Dio HTTP client configuration
│   ├── notifications/            # Notification service
│   ├── routes/                   # GoRouter navigation
│   ├── storage/                  # Hive & SharedPreferences helpers
│   ├── theme/                    # Material 3 theme
│   └── utils/                    # Utility functions
│
├── features/
│   ├── splash/                   # Animated splash screen
│   ├── location/                 # Location search, GPS, save/manage
│   │   ├── data/                 # Models, data sources, repository impl
│   │   ├── domain/               # Entities, repository contract, use cases
│   │   └── presentation/         # BLoC, screens, widgets
│   ├── weather/                  # Weather data and forecasts
│   │   ├── data/                 # Models (JSON), data sources, repository impl
│   │   ├── domain/               # Entities, repository contract, use case
│   │   └── presentation/         # BLoC, tabs (current/hourly/weekly), widgets
│   ├── settings/                 # App settings & notification controls
│   └── bottom_nav/               # Bottom navigation shell
│
└── main.dart                     # App entry point

🛠️ Tech Stack

Category Package
State Management flutter_bloc 9.1.1
Dependency Injection get_it 9.2.1
Navigation go_router 17.1.0
HTTP Client dio 5.9.2
Local Storage hive + hive_flutter
Preferences shared_preferences 2.5.4
Location (GPS) geolocator 14.0.2
Geocoding geocoding 4.0.0
Notifications awesome_notifications 0.11.0
Fonts google_fonts (PlusJakartaSans + Manrope)
SVG Icons flutter_svg 2.2.4
Loading Indicators flutter_spinkit 5.2.2
Weather API Open-Meteo (free, no key)

🚀 Getting Started

Prerequisites

  • Flutter SDK ^3.11.1
  • Dart SDK ^3.11.1
  • Android Studio / VS Code

Installation

  1. Clone the repository

    git clone https://github.com/CodeWithKhan07/weatherly.git
    cd weatherly
  2. Install dependencies

    flutter pub get
  3. Run code generation (for Hive adapters)

    dart run build_runner build --delete-conflicting-outputs
  4. Run the app

    flutter run

Note: No API key is needed — Weatherly uses the free Open-Meteo API.


📱 Permissions

The app requests the following permissions at runtime:

  • Location — For GPS-based weather detection
  • Notification — For daily weather push notifications

🧪 Testing

flutter test

Tests are located in the test/ directory, covering:

  • Feature BLoCs (weather, location, settings)
  • Use cases and repository logic
  • Widget tests

📂 Project Structure Highlights

Path Description
lib/main.dart App entry point, DI initialization
lib/core/routes/app_routes.dart GoRouter route definitions
lib/core/theme/app_theme.dart Material 3 theme configuration
lib/features/weather/presentation/ Weather tabs + BLoC
lib/features/location/presentation/ Location screens + BLoC

🌐 API

Weatherly uses the Open-Meteo API — a free, open-source weather API with no authentication required.

Fetched data includes:

  • Current conditions (temperature, humidity, wind, UV, precipitation)
  • Hourly forecast (48 hours)
  • Daily forecast (7 days)

📄 License

This project is open-source and available under the MIT License.


Built with ❤️ using Flutter

About

A premium Flutter weather app with liquid glass UI, powered by Open-Meteo. No API key required.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Packages

 
 
 

Contributors

Languages