dy / spect

Observable selectors in DOM
https://dy.github.io/spect
MIT License
77 stars 8 forks source link

v(v0, v1, v2) - observables as args #234

Closed dy closed 4 years ago

dy commented 4 years ago

Initializer now is only a function, not much use but ok. Multiargs patterns seems very handy, but not very convenient for creation. Extending initializer to be an observable would enable calcs - very useful! It should not support all possible observable cases - just symbol.observable, possibly old observable. Basically same as sube.

let v0 = v(0), v1 = v(1), v2 = v(v0, v1).map((v0, v1) => v0 + v1)

Then you don't necessarily need strui/from.

dy commented 4 years ago

Done