问题
I'm using Google's client login in my client-side javascript, which causes a popup to appear for auth and google login. However, I'd love to configure the sign-in to redirect to the popup's url, auth the user, then come back to my site instead.
I can't find anything in the documentation about configuring pop up vs redirect: https://developers.google.com/identity/sign-in/web/reference but I wanted to see if anyone else had success configuring the client-side login for this.
The alternative is using backend auth which I know allows redirects.
回答1:
The JavaScript library requires a window to pop up. If you want to implement it by redirecting users to auth, it will be a server side implementation like @osmanraifgunes pointed out in the comment.
来源:https://stackoverflow.com/questions/36648165/is-there-a-way-to-use-googles-javascript-client-login-without-a-pop-up