v0.15.0
Pre-release
Pre-release
Things published already under recent patch versions, but without public release noted:
- got
redux-saga/effects
andredux-saga/utils
working properly forwebpack2
androllup
users (or any other bundle which recognizesjsnext:main
/module
entry). Thanks to @ephys. How was it achieved can be seen here. Neat trick which I think is not publicly known and it was an issue for quite some time and also allowed me to help fixing this in some other libraries. - fixed
join(...tasks)
implementation, its not accepting an array of tasks, but rather a variadic number of tasks as arguments - implemented
cancel(...tasks)
in similar manner - implemented possibility for self cancellation, this means you can now
yield cancel()
inside a task and handle bothcancel(task)
+ self cancellation viacancel()
within the samefinally
block - fixed internal scheduler and its recursive nature, now its trampolining and cannot cause stack's overflow, thanks to @pbadenski and @wilsaj
- added
getContext
andsetContext
effects (thanks for the idea to @aikoven). It's not properly documented yet, but its a feature which allows sharing context properties across tasks without need to import them in each file or passing them explicitly through arguments. The feature is implemented as dynamic scoping which should sounds familiar for JS devs. In general you cannot share a context property from a child task to the parent, its only passed 'down'. You can read more in related issue and PR till its not documented. - got rid of
createSagaMiddleware({ onerror })
which got into library because of a typo and we have supported it for some time, please useonError
instead
New in this release:
- refactored
runSaga
API,runSaga(iterator, storeInterface)
got depreacted in favor ofrunSaga(storeInterface, saga, ...args)
. It allowed us to leverage the change internally so nowsagaMiddleware.run
became partially appliedrunSaga
, they wont now go out of sync (in the past changes and bug fixes had to implemented in both of them). cloneableGenerator
utils, which can ease ur unit testing when logic branching is needed, thanks to @nihauxcall([obj, 'method'])
- now you can pass a string as method's name which should be called on the passed contextall
effect - explicit effect for parallel effects, which is exactly what we had been supporting by accepting yielded arrays, so the latter is become deprecated now in favor of this explicitness which nicely maps to thePromise.all
API. Please use this from now on- improved TS typings, thanks to @aikoven for his continous support in this matter
Bug fixes:
- fixed issue with
eventChannel
s not closing automatically upon emittingEND
, thanks to @baldwmic
In the meantime we have also:
- got us https://redux-saga.js.org/ domain, thanks to @baldwmic
- got us a
rollup
ed UMD build, which is way smaller than the one which was produced by a webpack, thanks to the so called 'flat-bundling' - got us a logo! Thanks to @thekarland