cuongdevjs / reactjs-social-login

Group Hook ReactJS components for login social network
https://react-social-login.netlify.app
MIT License
168 stars 75 forks source link

You need to update your example code #130

Open parkoon opened 1 year ago

parkoon commented 1 year ago

access_type=offline condition is added on 2.6.3 so, your google login example code is not working as expected.

I think, you need to delete offline option in your google login example. thx.

amin-da commented 11 months ago

hi @cuongdevjs In the demo version of this library at the address below https://react-social-login.netlify.app/ google login send me CORS error and noting happening! why? google login is correct?

cuongdevjs commented 11 months ago

yes, cors sometimes happen when I try to get profile users, this process would be implemented on the server side instead. You won't see this if you only get the code or token and send it to the backend (use prop isOnlyGetToken or isOnlyGetCode)

amin-da commented 11 months ago

thanks for reply @cuongdevjs one another question This library is good for production? And there is no problem with next js 12.5 ?

cuongdevjs commented 11 months ago

thanks for reply @cuongdevjs one another question This library is good for production? And there is no problem with next js 12.5 ?

sure, I am using this library through multiple projects and it works well. the lib is absolutely compatible with the newest react version, but in NextJS, please use it with ssr = false, this library only works on the client side.

Shams-02 commented 11 months ago

@cuongdevjs

image

Still Getting this error: Cross-Origin-Opener-Policy policy would block the window.closed call.

with this implementation: ` <LoginSocialGoogle isOnlyGetToken client_id={""} onLoginStart={onLoginStart} onResolve={({ provider, data }: IResolveParams) => { setProvider(provider) setProfile(data) }} onReject={(err) => { console.log(err) }}

`

hassaan-glowfish commented 9 months ago

having same issue