I just set up new Firebase Hosting and my custom domain and my web page, etc...
Everything works great, except what is really bothering me are default Domains:
projectname.web.app
projectname.firebaseapp.com
Looking around googling, I have not found a solution, how to remove or disable them... Any suggestion? This seems really annoying. It could be a show stopper for me...
I have contacted Firebase Hosting help. According to them, you can not disable, remove, hide or make them private. Meaning they will always be there and be accessible to the public...
Their official answer;
<link rel="canonical" href="http://myapp.domain.com/" />
However, this did not work for me out of the box. I asked Google to re-index my web page (still waiting at this point to re-index).
//check if the url
if (window.location.hostname == "yourapp.web.app" ||
window.location.hostname == "yourapp.firebaseapp.com") {
window.location.href = 'http://yourcustomdomain';
}