Commit graph

59 commits

Author SHA1 Message Date
8c6833805b feat!(request-hook): add new request hook
This hook works only for endpoint with GET method.

* refac!(request-hook): add lazy prefix to request hook

BREAKING CHANGES: you need to rename all `useRequest` hooks to
`useLazyRequest`

* refac!(request-hook): add public request state

BREAKING CHANGES: User shouldn't see previous headers, variables and params.
It's only for hooks so it doesn't call request again. If you use these
state you should to remove it from your code.

* chore: update example

Closes #5
2020-11-05 23:26:56 +03:00
9b9150524c doc: fix example in readme 2020-11-05 22:16:19 +03:00
d1579694a1 chore: bump version 2020-11-05 00:31:04 +03:00
0c58bcc036
Merge pull request #6 from pleshevskiy/task-2
feat!(client): add client fetch based
breaking!(context): client prop instead base url
refac: change axios response to client response
chore(deps): remove axios
chore: update example
2020-11-04 23:25:59 +02:00
243f4f77e5 feat!(client): add client fetch based
breaking!(context): client prop instead base url
refac: change axios response to client response
chore(deps): remove axios
chore: update example

Closes #2
2020-11-05 00:23:57 +03:00
c20198f14f chore: add movies example 2020-11-04 21:23:29 +03:00
08ca8827c6
Merge pull request #4 from pleshevskiy/task-1
doc: add small example to readme
doc: add save to deps flag
2020-11-04 12:42:00 +02:00
3d606b86cd doc: add small example to readme
doc: add save to deps flag

Closes #1
2020-11-04 13:40:40 +03:00
e9c18c9fea Initial commit
feat(context): add context for request
feat(client): add hook for get memo rest client
feat(endpoint): add endpoint object for configure rest methods
feat(request): add request hook
refac(request): return cached data for same query
refac(request): remove void variables for endpoints
feat(request): add headers to request cache
2020-11-04 00:39:14 +03:00