My point is exactly that _you don’t need to_. Why is it important? The effects are an implementation detail.
Conversation
Trying to figure out how this is different from any object which performs effects when it e.g. receives a message.
2
My remaining concern is: most of most view models are totally pure. Why not isolate the impurities?
1
That isolation is an implementation detail (but maybe could still be valuable), because the signal interface isolates it.
1
Consumers of the signal interface don’t know or care whether it’s impure, because the effects have been isolated already.
2
I definitely care whether the VM's subscription is pure for the same reason I care if a function I'm calling is pure.
1
I’m not sure what “subscription” you’re referring. Signals are usually activated (directly or indirectly) by the view.
2
What I mean is: if I send an event to this signal, are effects going to happen?
1
Why are you sending events? That should be represented as a stream of inputs.
1
When your whole program is a signal network, you don’t think about whether “this specific signal” does stuff.
2
1
1
Replying to
OK. I really, really don't understand what you're saying, but I'm willing to believe that's because I haven't made such a pgm
Replying to
Here’s an example. A button that should fetch some data from a service and display it in a label on-screen.
1
If you look at it holistically, the new label value is an output, transformed from the input which is a button press.
1
Show replies

