搜尋套件、儲存庫與 APP 分類

GitHub 儲存庫denweeLabs/factlyapp

Denwee:每日趣味知識

Denwee:每日趣味知識是一個開源的Flutter應用,展示適用於現實專案中的乾淨、可擴展架構 📱

Denwee:每日趣味知識 專案封面
星標
79
分支
15
最近推送(UTC)
2026年8月29日
專案狀態
未封存

原始 README

以下為英文專案原文快照,最新內容請造訪 GitHub。


Denwee: Daily Trivia
Denwee: Daily Trivia

Discover short, easy-to-understand, memorable facts every day!

Download on the App Store Get it on Google Play

Mockup

Denwee is an open-source mobile application built with Flutter. It delivers personalized daily facts based on user-selected interests and supports push notifications, localization, and a modular, scalable architecture inspired by SOLID principles.

🎥 Onboarding

Click to watch full app onboarding (30s):

Onboarding Preview

🎨 Features

🛠 Tech Stack

Layer Technologies Description
Frontend (Open Source) Flutter, Dart, Firebase Cloud Messaging, Localizations Client app, responsible for UI, notifications, localization, and user interactions
Backend (Closed Source) Supabase, PostgreSQL, Supabase Edge Functions, ChatGPT API (Batch), Cron/Scheduled Jobs Handles authentication, facts generation, data storage, multi-device token management, and notification scheduling
Infrastructure Supabase (Database, Auth, API)
Firebase (Push Notifications, Analytics, Crashlytics)
Manages user accounts, data, push notifications, analytics, and crash reporting

📦 Primary Packages

Package Purpose
flutter_bloc State management
get_it Dependency injection
app_links Deep links
drift Local database
dio Network requests
easy_localization Multi-language support
animate_do Animations

🧩 Architecture

This section describes the architectural structure of the application and its internal dependency model. The design follows principles inspired by Clean Architecture, with emphasis on separation of concerns, modularity, and long-term maintainability.

Folder Structure

The project is organized using a feature-based structure with explicit separation between domain, data, and presentation layers. The following diagram illustrates the base structure of the project:

flowchart TB

subgraph Presentation[" "]
  direction TB
  page
  bloc
  widget
  shared
end

subgraph Feature[" "]
  direction TB

  data --> model_m[model]
  data --> repo_m[repo]
  data --> source_m[source]

  domain --> entity_d[entity]
  domain --> repo_d[repo]
  domain --> source_d[source]
  domain --> use_case_d[use_case]
end

lib --> core
core --> feature
feature --> Feature

lib --> presentation
presentation --> Presentation

The presentation/ folder is kept outside of the core/ directory to enforce strict separation between application logic and UI components. Below is what each layer is responsible for using the Profile feature as an example for typical files ⬇️

Domain Layer
Folder Responsibility Typical Files
entity/ Business models profile.dart
profile_failure.dart
use_case/ Business operations get_profile_use_case.dart
repo/ Repository contracts profile_repo.dart
source/ Data source contracts profile_local_source.dart
profile_remote_source.dart

The domain layer contains pure business logic and application rules for implementing feature behavior in the application. It defines core use cases and entities and remains independent of external frameworks and data sources.

Data Layer
Folder Responsibility Typical Files
model/ Data transfer objects (DTOs) profile_dto.dart
profile_response_dto.dart
repo/ Repository implementations profile_repo_impl.dart
source/ Local / Remote data source implementations profile_local_source_impl.dart
profile_remote_source_impl.dart

The data layer is used for retrieving, storing, and transforming external data for application features. It implements domain contracts and performs DTO-to-entity mapping.

Presentation Layer
  • pages/ contains all application screens
  • bloc/ contains Cubits and Blocs for state management
  • widget/ contains reusable UI components
  • shared/ contains routing, theming, constants, utilities, etc...

The presentation layer is separated from core feature modules as a deliberate design choice. This structure reflects a personal preference for improved screen discoverability and centralized UI infrastructure.

Dependency Injection

The application uses annotation-based dependency injection with injectable and get_it to connect layers and enable controlled execution flows. Dependencies are registered automatically through code generation.

Example objects injection:

@LazySingleton()
class ProfileCubit extends Cubit<ProfileState> {
  final GetProfileUseCase _getProfileUseCase;

  ProfileCubit(this._getProfileUseCase) : super(ProfileState.initial());
}

@LazySingleton()
class GetProfileUseCase {
  final ProfileRepo _profileRepo;

  const GetProfileUseCase(this._profileRepo);
}

Example resolution hierarchy:

ProfilePage
  → ProfileCubit
    → GetProfileUseCase
      → ProfileRepository
        → ProfileRemoteSource / ProfileLocalSource
          → API

🖌️ Assets

🚀 How To Run

To run this application, you'll need Flutter of version 3.35.5 or higher:

# Get all packages
flutter pub get

# Generate localization files
flutter pub run easy_localization:generate -S "assets/translations" -O "lib/presentation/shared/localization"

# Generate localization keys
flutter pub run easy_localization:generate -S "assets/translations" -O "lib/presentation/shared/localization" -o "locale_keys.g.dart" -f keys

# Build runner
dart run build_runner build --delete-conflicting-outputs

# Run dev environment
flutter run --flavor dev -t lib/main_dev.dart

# Run prod environment
flutter run --flavor prod -t lib/main_prod.dart

🤝 How To Contribute

Denwee projects are crafted by a solo enthusiastic developer across Mobile, Web, and Backend technologies. Your contributions, no matter how big or small, are always welcome! Here’s how you can help:

  • Open PR's – fix bugs, add features, or improve existing code.
  • Submit Issues – report bugs, request features, or suggest improvements.

🌐 You May Also Like

Explore the Denwee App landing page, built with Flutter Web. This simple landing page is also open-source 🔥 Check it out

🏆 Credits

Some design elements and animations were inspired by Reflectly App, adapted and implemented originally for Denwee. Definitely check out their awesome product!

❤️ Support

If this project helped you, a quick review on the App Store or Google Play would really mean a lot! For any questions or support, please reach out to support@denwee.com 🫶

Buy Me A Coffee

📃 License

License: MIT

Denwee GitHub avatar
GitHub 作者

Denwee ↗

Denwee projects are crafted by a solo enthusiastic developer across Mobile, Web and Backend technologies 🫶

語言DartRubySwiftShellKotlinObjective-C

分類

依賴 Flutter 元件

使用的依賴

依賴清單 80 項

App 分類

如何選擇適合專案的儲存庫?

先依使用情境篩選,再比較專案活躍情況,最後到原始儲存庫確認使用要求。

  1. 透過儲存庫名稱、作者或描述搜尋,再依技術分類縮小範圍。
  2. 綜合星標、分支與最近推送比較專案;星標反映社群關注,不保證品質。
  3. 使用前在 GitHub 確認 README、授權條款與 Issues。

來源與維護

“A repository is the most basic element of GitHub.”

GitHub Docs — About repositories ↗