You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Google Auth has several more options that are not exposed.
In particular for Server/Client cases where the user wants to authorize the server to make API calls, being able to obtain a code that the server can use to obtain a token and a renew token is important. The React package react-google-login offers
<GoogleLoginclientId="your-client-id"onSuccess={handleGoogleResponse}onFailure={handleGoogleResponse}cookiePolicy={'single_host_origin'}accessType='offline'// To get a non-expiring refresh tokenprompt='consent'// To force the code to allow to obtain a refresh-token each time (otherwise only the first in a session will get a refresh-tokenresponseType='code'// Obtain a code to pass to the server/>;
Google Auth has several more options that are not exposed.
In particular for Server/Client cases where the user wants to authorize the server to make API calls, being able to obtain a code that the server can use to obtain a token and a renew token is important. The React package
react-google-login
offersAn added benefit is that the code method is safer than passing a token as documented by Google.
The text was updated successfully, but these errors were encountered: