Replies: 1 comment
-
Hi @mitsuruog I just went down this rabbit hole and found an answer here TkDodo/blog-comments#84 (comment) async loader() {
const promise = store.dispatch(api.endpoints.myEndpoint.initiate(someArgument))
await promise // wait for data to be there
promise.unsubscribe() // remove the subscription. The data will stay in cache for 60 seconds and the component can subscribe to it in that timeframe.
} |
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
-
I tried several times but it never worked. 😞
Does anyone have a working example?
Beta Was this translation helpful? Give feedback.
All reactions