Promise driver + cache #526
Unanswered
BigBadAlien
asked this question in
Q&A
Replies: 2 comments
-
We would neet to probably switch to sth like: const fetchPhoto = id => ({
type: FETCH_PHOTO,
request: {
promise: () => axios.get(`https://jsonplaceholder.typicode.com/photos/${id}`),
},
meta: {
cache: true,
}
}); |
Beta Was this translation helpful? Give feedback.
0 replies
-
or just use... axios driver ;) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
If we call the action above the promise will be resolved anyway despite on is it cached or not because of Promise specification (Promise will try to start right after definition). Do we have a way to avoid it?
Beta Was this translation helpful? Give feedback.
All reactions