Releases: redux-saga/saga-query
Fix react optional
v2.1.2 wrong key for exports
Fix react optional
v2.1.1 exports in package json
React optional and new uri function
- React is now optional
- New api
api.uri(uri: string)
which returns all the http methods scoped to the uri
React hooks
Introducing a couple of react hooks that will make it easier to leverage saga-query.
- useQuery: hook to automatically load the data as well as the associated loader
- useSimpleCache: hook to use a simple cache with its data and loader
Better default error handling
errorHandler
which is placed inside requestMonitor
will now display an error from where the error originated from as well as post the ctx
object. This should make debugging when an endpoint throws an error easier.
Update undo middleware and upgrade robodux
There was a regression from the v1 release where undoer
middleware wasn't working as expected when calling undo()
. I also upgraded robodux.
simplify ctx.loader
I modified ctx.loader to be simpler to interact with
`prepareStore` and revamped middleware
This release adds some breaking changes. In particular, some middleware have been renamed:
loadingTracker
->loadingMonitor
loadingMonitor
now drops the loaders
parameter in favor of leveraging prepareStore
.
prepareStore
helps end-developers setup their redux store loaded with redux-saga
, redux-batched-actions
, and a couple of reducers: loaders
and data
. Middleware now use these assumptions to make the developer experience more unified and ergonomic.
We recommend everyone to use prepareStore
before creating their redux store.
We added two new composed middleware: requestMonitor
and requestParser
. These both will provide a better developer experience for monitoring request lifecycle and parsing the request.
Public Release
v0.0.18 create proper action