How to change the app name for firebase authentication (what the user sees)

后端 未结 5 419
野趣味
野趣味 2020-12-13 04:39

Thanks to firebase v 3.9.0, my social OAuth is working great in my ionic app. I have one little change I\'d like to make. When prompted to login, it says \"Sign in to cont

5条回答
  •  抹茶落季
    2020-12-13 04:55

    This is what worked for me:

    1. Change the Firebase configuration you set in your code to have authDomain: "insertyourdomainnamehere.com"
    2. Press on the "Sign In With Google" on your app and see the error you get due to this change. Follow directions of the error.

    The error lead me to https://console.cloud.google.com/apis/credentials (Google Cloud Platform > APIs & Services > Credentials).

    1. On that page, look at "OAuth 2.0 Client IDs" section.
    2. For me, there is only one record "Web client (auto created by Google Service)." Click the edit button on it.
    3. Look for "Authorized redirect URIs" section. In that section, add: https://insertyourdomainnamehere.com/__/auth/handler.

    Then it should work! It should now say "Sign in to continue to yourdomain.com."

提交回复
热议问题