How to disable the default domain in firebase hosting

I host the site on Firebase hosting. It has a default url of myapp.firebaseapp.com. I have set up a custom URL for my application and this is sub.domain.com. The problem I have is that both are still available. Users can access the app with myapp.firebaseapp.com and sub.domain.com. I need users to have access only to sub.domain.com.

Is there a way to disable the default domain in the Firebase console or do I need to do this using rewrite or redirect?

Any help would be greatly appreciated. I searched around and could not find any information on this issue. Below is a screenshot showing that both domains are configured correctly.

enter image description here

+16
2

, ( , ), . URL, Javascript. , (window.host), , URL, .

0

. - .

, .

0

Source: https://habr.com/ru/post/1686883/


All Articles