Skip to content

React Native small project showing how to properly do Auth Exchange #1202

Answered by JoviDeCroock
ghost asked this question in Q&A
Discussion options

You must be logged in to vote

The authExchange is mainly meant for OAuth flows where you can have errored tokens due to needing a refresh, .... so it enables you to do these flows without having to account for retrying manually and so on.

Yes you always need wonka, as described in our exchanges documentation, this is our main pattern to allow for extensability within urql.

This is an example, https://codesandbox.io/s/billowing-pond-lrmoj?file=/src/index.tsx:507-510 RequestInit is showing an error here because CSB can't find it but it's a global in TypeScript https://microsoft.github.io/PowerBI-JavaScript/interfaces/_node_modules_typedoc_node_modules_typescript_lib_lib_dom_d_.requestinit.html

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@ghost
Comment options

Answer selected by kitten
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant