keppelen / react-facebook-login

A Component React for Facebook Login
1.18k stars 406 forks source link

State params #334

Open sebauru87 opened 2 years ago

sebauru87 commented 2 years ago

What is the correct way when using the state params? I need to keep several utms query params when android phones.

st=state123abc&ds=123456789

According to facebook developers if you use the SDK from them, they use it like this

state={"{st=state123abc,ds=123456789}"}.

No matter how I use it, at the end of the URL, once I logged in and redirect, I got :

state={st%3Dstate123abc%2Cds%3D123456789}

Thanks

greatSumini commented 2 years ago

you have to decode that value. use decodeURIComponent 😃