Following from Channels and Unit
But decided to to do a separate thread, since maybe i have some lack of knowledge in current state of VL.
Anyways,i gave a go to Reactive Channels, since that’s prolly most closest entry point to get to MVVM pattern architecture. Few words about architecture i’m trying to achieve, with notes how it applies to VL:
- Model that is serializable, and holds only data (Record in VL case)
- ViewModel that holds model, manages view logic and provides bindings (bindable properties and commands) (Seems to be a good option for a process node, but actually a Class converted to Process)
- View (Some ImGui widgets)
So, the first question was how to fire a Command in such way so i can have a trigger back in ViewModel:
I decided to test an that kinda looks like a proof of concept:
However i stumbled across SelectByPath seems to create an exclusive sink in case of Unit
:
seems to be related to GetSlice Channel problem
My point is that would be nice, to pass somehow Operation instead of Unit
that would make that pattern play nicely with current architecture.
Obviously there few other questions like Async Operation
In any case here is my simple test, if anyone have suggestion or improvements.
MVVMTest.vl (25.6 KB)