2
votes

I am developing a cordova-application that is supposed to be used within the browser and on iOS/Android.

I am using Firebase-Auth with Email, FB, and Google-Auth as Providers.

As cordova-apps are served from file:// and oAuth needs a redirect-URL using firebase-ui-web does not work out of the box on mobile plattforms.

Is there any way around that or do I need to use the native firebase-bindings and pass the oauth-token somehow up to the webapp. If so, how?

2

2 Answers

6
votes

Google have just released this https://firebase.google.com/docs/auth/web/cordova

The Firebase JavaScript SDK (v3.9.0) is now available. It includes updates to Authentication and a bugfix for Cordova apps. To install this SDK, see Add Firebase to your JavaScript Project.

-1
votes

firebaseui-web currently doesn't support signInWithRedirect/Popup in Cordova as firebase auth doesn't support it yet but the Firebase team is working on a solution for that. Check this link for more information on a fallback solution: https://groups.google.com/forum/#!searchin/firebase-talk/cordova%7Csort:relevance/firebase-talk/eUzTjj8mVa4/stvOIL75FwAJ