The Authentication Emulator allows you to quickly and safely test new changes to how your app handles authentication. I saw this library had no way to connect to the emulator, so I made an issue last year asking about it (#160). It became stale, but since then I've learned how to add it in myself.
By replacing https:// with http://localhost:9099/ in the API calls, we are able to use this library for the emulator with no other changes.
Initialization looks like this:
var authProvider = new FirebaseAuthProvider(new FirebaseConfig(ApiKey, true));
The only difference is there is now a new boolean parameter asking if you would like to use the emulator or not. It is optional and defaults to false so there will be no breaking changes when users update. This boolean will allow easy switching between dev environments that use the emulator vs prod environments that do not. A third parameter allows you set the port if you have decided to not use the default port of 9099
The Authentication Emulator allows you to quickly and safely test new changes to how your app handles authentication. I saw this library had no way to connect to the emulator, so I made an issue last year asking about it (#160). It became stale, but since then I've learned how to add it in myself.
By replacing
https://
withhttp://localhost:9099/
in the API calls, we are able to use this library for the emulator with no other changes.Initialization looks like this:
var authProvider = new FirebaseAuthProvider(new FirebaseConfig(ApiKey, true));
The only difference is there is now a new boolean parameter asking if you would like to use the emulator or not. It is optional and defaults to false so there will be no breaking changes when users update. This boolean will allow easy switching between dev environments that use the emulator vs prod environments that do not. A third parameter allows you set the port if you have decided to not use the default port of 9099