effector-react v0.18.1 Release Notes
-
- โ Add
forward
: common function for forwarding updates and events
import {forward} from 'effector' const unsubscribe = forward({ from: Event | Store, to: Event | Store | Effect, })
- โ add support for storages in
store.on
import {createStore} from 'effector' const $name = createStore('name') const $counter = createStore(0).on(name, (count, name) => count++)
- ๐ Allow to pass
{handler: Function}
as second argument tocreateEffect
import {createEffect} from 'effector' const callApiFx = createEffect('call api', { async handler(url) { const res = await fetch(url) return res }, })
- ๐ Make
effect.use
return the same effect instead of void (ability to chain method calls)
import {createEffect} from 'effector' const callApiFx = createEffect('call api').use(url => fetch(url))
- โ Add