firelive 0.0.1 copy "firelive: ^0.0.1" to clipboard
firelive: ^0.0.1 copied to clipboard

Lightweight Firebase Firestore state manager using ValueNotifier.

πŸ”₯ Firelive #

Firelive is a lightweight, real-time Firebase Firestore state management solution using Flutter’s ValueNotifier. It offers two versions β€” V1 with advanced state handling, and V2 for minimal, fast use. Built for developers who want full control and performance without heavyweight state management libraries.


✨ Features #

  • πŸ“‘ Real-time Firestore collection updates
  • ⚑ ValueNotifier-based reactivity (simple, fast)
  • 🧭 Two versions: Full (V1) and Lite (V2)
  • πŸ› Built-in error and loading state (V1)
  • ⏸️ Pause/resume stream manually (V1)
  • 🎯 Great for Firebase-powered Flutter apps (web, mobile, desktop)

πŸ”€ Versions #

πŸ”Ή FirestoreLiveListV1 #

Includes loading, error, pause/resume, and real-time updates.

final users = FirestoreLiveListV1<UserModel>(
  path: 'users',
  queryBuilder: (col) => col.orderBy('created_at'),
  fromMap: (data, id) => UserModel.fromMap(data, id),
);

await users.listen();

Use in a widget:

ValueListenableBuilder(
  valueListenable: users.notifier,
  builder: (_, list, __) => ListView(
    children: list.map((e) => Text(e.name)).toList(),
  ),
);

Cleanup:

await users.dispose();

πŸ”Ή FirestoreLiveListV2 #

A minimal, fast version without loading/error/pause support.

final users = FirestoreLiveListV2<UserModel>(
  collection: 'users',
  queryBuilder: (col) => col.where('active', isEqualTo: true),
  fromMap: (data) => UserModel.fromMap(data),
);

await users.listen();

πŸ“ File Structure #

lib/
β”œβ”€β”€ firelive.dart           # Export both V1 and V2
└── src/
    β”œβ”€β”€ firestore_live_list_v1.dart
    └── firestore_live_list_v2.dart

πŸ§ͺ Example #

Use the /example directory to try Firelive with a real Firebase setup.


πŸ›  Installation #

Add to your Flutter project:

dependencies:
  firelive: ^0.0.1

πŸ‘¨β€πŸ’» Author #

Mohamed Razan
πŸš€ Flutter & Firebase Developer
πŸ“§ mohamedrazanr@gmail.com
πŸ™ GitHub: github.com/Mohamedrazan
πŸ’Ό LinkedIn: linkedin.com/in/mohamed-razan-35b073245


πŸͺͺ License #

MIT License β€” free to use, modify, distribute, and contribute.


🀝 Contributions #

Contributions and feedback welcome! Submit an issue or PR on GitHub.

Built with simplicity and performance in mind β€” no Provider, Bloc, or Riverpod needed.

0
likes
130
points
142
downloads

Publisher

unverified uploader

Weekly Downloads

Lightweight Firebase Firestore state manager using ValueNotifier.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

cloud_firestore, firebase_core, flutter

More

Packages that depend on firelive