Thursday, May 9, 2024
 Popular · Latest · Hot · Upcoming
16
rated 0 times [  19] [ 3]  / answers: 1 / hits: 16082  / 8 Years ago, thu, may 19, 2016, 12:00:00

I'm trying to use Firebase with Electron. When installing it just like I would on a web page it doesn't work because Electron pages are hosted locally and don't have a hostname. This is the error I'm getting...



Uncaught Error: This domain is not authorized for OAuth operations for your Firebase project. Edit the list of authorized domains from the Firebase console.


I can't add an empty (or wildcard) authorized domain to the Firebase console so I'm therefore stuck. Does anybody have any ideas of how to work around this?



edit: Here's the code I'm using, it's just the standard boilerplate, nothing extra...



<script src=https://www.gstatic.com/firebasejs/live/3.0/firebase.js></script>
<script>
var config = {
apiKey: AIzaSyBvmmPB0_Oddc-02cUj3Ntt3wi8jSxxxx,
authDomain: xxxxx-d24ad.firebaseapp.com,
databaseURL: https://xxxxx-d24ad.firebaseio.com,
storageBucket: ,
};
firebase.initializeApp(config);
</script>

More From » html

 Answers
20

For now, you can suppress this error by removing the authDomain line from your config. authDomain is needed for the Auth signInWithPopup/signInWithRedirect operations, but everything else should work.



A version of the library that throws that error only when you actually try to do a signInWithPopup/Redirect is in the works.


[#62102] Tuesday, May 17, 2016, 8 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
timothyc

Total Points: 233
Total Questions: 103
Total Answers: 103

Location: Jordan
Member since Thu, Aug 5, 2021
3 Years ago
;