Hi @Tzypo,
If you want to continue to use the auth0-react
SDK, you could pass the token to the action by using useAuth0
or withAuth0
, but I agree that you probably want to handle that within the action instead of each component since you are using Redux.
The auth0-react
SDK is built on top of the Single Page App SDK. Since you don’t want to use the React wrapper for hooks and components, you may want to use auth0/auth0-spa-js
instead.
This topic shows an example of using auth0/auth0-spa-js
and moving the auth0client outside of the Auth0 Provider so that actions are : Using @auth0/auth0-spa-js outside of a React Component - #4 by klequis
Here are some additional resources you may find helpful for securing React/Redux apps: