flutter_provider
2.1.0, released 5 years ago by an unverified publisher
A lightweight generic provider using InheritedWidget to expose values in Flutter.
WASM-ready
What it does
It offers Provider, Providers, Consumer widgets and extensions to expose and retrieve objects via InheritedWidget. It simplifies dependency exposure without writing custom InheritedWidgets.
AI-written summary of version 2.1.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need simple state or object sharing without extra boilerplate
- You prefer a minimalistic alternative to the official provider package
Skip it when
- You require advanced features like scoped providers, auto-dispose, or code‑generation
- You need built‑in support for state‑notifiers or async providers
Strengths
- Very small and easy to understand
- No code‑generation or additional tooling required
Weaknesses
- Limited feature set compared to more mature packages
- Less community support and fewer extensions
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 1
final foo = Foo();
Providers(
providers: [
Provider<Foo>.value(foo),
],
child: const HomePage(),
);Alternatives
Packages that do the same job and could replace flutter_provider.
- provider
Official, widely used, more features and community support
81Compare - flutter_riverpod
Offers a robust, compile‑time safe provider system with many extensions
93Compare
Works with
Packages commonly used together with flutter_provider: ones it builds on, ones built on it, and its own family.