#capture function

1 messages · Page 1 of 1 (latest)

raven sandal
slow stream
#

capture is sugar over pure, if that gives you any hints

#
actions: {
  doStuff: pure((ctx, ev) => {
    const actions = [];
    const exec = (action) => actions.push(action);

    exec('something');
    if (/* ... */) {
      exec('something else');
    }

    return actions;
  })
}