Brenton Simpson
1 min readMay 14, 2015

--

Does Bacon have an equivalent to Kefir’s Property (a stream that remembers its last value)?

It seems to me you’d want to build another layer of abstraction on top of that to handle your API calls. Something like this:

var selectFromStoreStream = function (storeStream, keyStream) {
var store = storeStream.lastValue;
var key = keyStream.lastValue;
if (store.has(key)) {
return store.get(key);

} else {
storeStream.fetch(key);
return null;
}
};
var currentThingStream = selectFromStoreStream(
currentThingsStream,
currentThingIDStream
);

I’m also interested in exploring the benefits of functionally reactive Flux. I drafted a post to that end, but put it on hold while I’ve been exploring Nuclear.js.

--

--