问题
Error (inspected from html):
details: "Not a valid origin for the client: http://localhost:3000 has not been whitelisted for client ID 830959654564-inlhib5r4afjbm4ebt1e43gt07bpvve5.apps.googleusercontent.com. Please go to https://console.developers.google.com/ and whitelist this origin for your project's client ID." error: "idpiframe_initialization_failed"
Problem: Tried using localhost:3000 and my local ip address given from React. I've tried clearing the cache. I've tried using other browsers.
Blank Google OAuth
回答1:
Well still no real solution but I created a new project and have reached no problems yet.
回答2:
For me, this only worked when I created a project directly from https://console.developers.google.com/.
The project I created "inline" at https://developers.google.com/identity/sign-in/web/sign-in never seemed to see the origin config.
来源:https://stackoverflow.com/questions/52860207/google-oauth-api-blank-login-because-localhost-is-not-whitelisted