0
votes

I'm trying to implements the basic JavaScript Code Samples inside an Electron app. I've successfully created my project and added an API key credentials in the Google Console.

However, when I try the basic samples into an Electron app, I get the following error:

Refused to display 'https://accounts.google.com/o/oauth2/auth?client_id=...' in a frame because it set 'X-Frame-Options' to 'SAMEORIGIN'.

What should I do to avoid that?

1

1 Answers

0
votes

Sometimes the Client ID can be the issue. See Here

You can also use CORS if that does not work:

https://developers.google.com/api-client-library/javascript/features/cors