Google Authentication guide confusing

Hello all,
Is the sample code in the Authentication guide for Google (Authentication - Expo Documentation) only for the web apps?? Because it looks like it with the way it is formatted in the doc, looks like it’s together with the Web Apps subject, and i haven’t been able to get it to work as described yet.

Thanks

The guide covers web apps too, not only, just WebBrowser.maybeCompleteAuthSession(); is only useful for web. A possible point of confusion is how it works with Expo Go, where you need to use a “Web Application” type key, but that’s just because of the inner workings, it doesn’t mean it’s a web app.

Thank you very much @gloredo, but more specifically, I’m referring to the actual code example given at the bottom of the Google section. It looks like it’s only for the Web app sub-section, or should that code work for all platforms, including native/standalone (once the correct credentials are setup of course)?
many thanks

Expo always tries to offer cross-platform code, basically the exceptions are unsupported modules (some are not implemented for web or are platform specific) and specific snippets like WebBrowser.maybeCompleteAuthSession(). In summary, the code snippets from the authentication guide work on Android, iOS and Web if you use WebBrowser.maybeCompleteAuthSession().

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.