Hey everyone, I have a question regarding Flow.
I have an architecture that looks something like this: UI + ViewModel <- Service <- Repository
In this pipeline, Service is maping data from the repository for something that can be consumed by the ViewModel using the map {} operator.
Now comes my question:
Is it a good idea to put code that changes the system state inside this map or is this a bad idea and I should only map data from one type to another inside the flow ?
So basically I would like to schedule/unschedule some alarms as data is registered/unregistered in the repository, but I have the feeling that a flow is more like a query to collect data than some method that can change the system state.
I would appreciate some input on what is an expected behavior of a Flow and how it can be use to model system behavior.
Thank you