Event-driven architecture using Flutter Hooks, Rust, and StreamController #352
vincent-herlemont
started this conversation in
General
Replies: 1 comment
-
Why don't you use Riverpod's StreamProvider to handle Rust's stream input? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I am implementing an event-driven architecture for a Flutter application, which consists of three parts:
StreamController.broadcast()
.useEventStream<T>
Schema example:
Here is the part 2 which receives events from Rust:
Here is the custom hooks
useEventStream<T>
:And in each component, we have:
I have a few questions regarding this architecture:
👉 It is worth noting that the event stream could be significant, with several hundred events per second during peak times.
Any feedback or suggestions for improvements are welcome :)
Beta Was this translation helpful? Give feedback.
All reactions