Adding Cordova Plugins
NOTE: This "Legacy" section is old and is now meant for Advanced Developers who want to export using the Cordova CLI.
For most users, "Firebase Auth Pro Mobile" Plugin is recommended.
If you are using OAuth Providers for your project, run the following commands:
(You will get this error at 'cordova-plugin-compat'. Ignore it.)
2. In the Firebase Console, go to Dynamic Links and click on get started. Now add a Dynamic Link Domain like example.page.link
3. Note the above code. Here, replace DYNAMIC_LINK_DOMAIN with the domain you just added. Also replace AUTH_DOMAIN with authDomain in your Firebase Console > Project Settings > SDK snippet.
4. Copy that code, open config.xml file in your Cordova project folder and find </widget>. Paste that code just before this word.
5. Go to YOUR_CORDOVA_APP_LOCATION\plugins\cordova-universal-links-plugin\hooks\lib\android, open manifestWriter.js
6. Replace the highlighted line with this:
var pathToManifest = path.join(cordovaContext.opts.projectRoot, 'platforms', 'android', 'app', 'src', 'main', 'AndroidManifest.xml');
If you are using Phone Auth for your project, run the following commands:
If you have installed plugins for OAuth as well, run this command:
Add an Android app to your Firebase Project from the Console. Go to Console Settings, and Download google-services.json
4. Paste the google-services.json file at YOUR_CORDOVA_APP_LOCATION\platforms\android\app