Comments (7)
OK, I found a way to do this efficiently using Expando
. ReactiveValueNotifier
is now a subclass though, not an extension. Published in 2.0.0. Thanks for the report!
from flutter_reactive_value.
Does its fixed now? No memory leaks?
from flutter_reactive_value.
@alwerr There should be no memory leaks now, correct. But it is hard to test this, because testing this requires the garbage collector to be triggered.
from flutter_reactive_value.
Ok. thanks, great package, @lukehutch do you still use it?
from flutter_reactive_value.
I actually don't use it anymore, because I have much more complex needs for ValueNotifiers now, such as defining a ValueNotifier that reactively responds to changes in multiple other ValueNotifiers (allowing a reactive DAG of notifies to be built). Also I use my other package, Persistent ValueNotifier a lot, and that no nonger works together with ReacrltiveValueNotifier as of version 2.0. So at this point I have about 8 different subclasses of ValueNotifier built for different purposes, and I just use them with ValueListenableBuilder, or my own alternative to that class which I also built (but haven't published yet).
The simplest thing to use today in general is simply ValueNotifier with ValueListenableBuilder, since both are included in Flutter.
from flutter_reactive_value.
Persistent ValueNotifier looks really helpful, so I guess I would use ValueNotifier with ValueListenableBuilder too, are they working in stateless widget too? like in this package?
from flutter_reactive_value.
Yes, ValueListenableBuilder is a stateful widget that rebuilds when the ValueNotifier it is watching changes. It can be used inside any widget (including a stateless widget). It's very simple to use. And PersistentValueNotifier works perfectly with it.
from flutter_reactive_value.
Related Issues (5)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from flutter_reactive_value.