# Google Connection failing in Electron and Angular 4 with Lock 10.15

**URL:** <https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441>\
**Category:** Get Help\
**Tags:** auth0-lock, angular4, google, electron\
**Created:** [May 2, 2017, 2:26pm UTC](https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441 "2017-05-02T14:26:11Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![geoffrey](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@geoffrey](https://community.auth0.com/u/geoffrey)\
**Post date:** [May 2, 2017, 2:26pm UTC](https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441/1 "2017-05-02T14:26:11Z")

</div>

Hello.

I have an Electron + Angular 4 application which I am trying to wire with auth0, and I am not having success with the Google connection.

(Using Lock 10.15.)

I have

- tried both `Native` and `SPA` Client Types
- set Allowed Callback URLs
- set CORS
- walked through multiple posts
- reviewed multiple repos
- read auth0-lock issues
- tried standard and hash location strategy quickstarts
- tried multiple `options` configurations

What am I missing? I suspect it is something obvious.

Cheers,  
Geoffrey

* * *

Google Fails in Application  
!]([https://storage.googleapis.com/qxflmk-dev-public/GoogleButtonNoResponse.gif](https://storage.googleapis.com/qxflmk-dev-public/GoogleButtonNoResponse.gif))

But shows it works in the auth0 logs:  
!]([https://storage.googleapis.com/qxflmk-dev-public/auth0-log.png](https://storage.googleapis.com/qxflmk-dev-public/auth0-log.png))

Twitter Behaves as Expected  
!]([https://storage.googleapis.com/qxflmk-dev-public/TwitterFine.gif](https://storage.googleapis.com/qxflmk-dev-public/TwitterFine.gif))

* * *

**Blog Post**

> **[Create a Desktop App with Angular 2 and Electron | Auth0](https://auth0.com/blog/create-a-desktop-app-with-angular-2-and-electron/)**
>
> Build a simple image calculator app with Angular 2 and Electron

**Standard Quickstart (Angular 2)**

[https://auth0.com/docs/quickstart/spa/angular2/01-login](https://auth0.com/docs/quickstart/spa/angular2/01-login)

**HashLocationStrategy (Angular 2)**

[https://auth0.com/docs/quickstart/spa/angular2/01-login#use-with-hashlocationstrategy](https://auth0.com/docs/quickstart/spa/angular2/01-login#use-with-hashlocationstrategy)

**Forum**

> **[Auth0 Community](https://community.auth0.com)**
>
> Community for Auth0, the identity Infrastructure built for developers.

**Repos**

[https://github.com/faxad/cartify/blob/upgrade/4-0-0/src/app/shared/auth.service.ts](https://github.com/faxad/cartify/blob/upgrade/4-0-0/src/app/shared/auth.service.ts)

---

<div class="post-metadata">

**Author:** ![Abhishek\_Hingnikar1](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@Abhishek\_Hingnikar1](https://community.auth0.com/u/Abhishek_Hingnikar1)\
**Post date:** [May 3, 2017, 11:50am UTC](https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441/2 "2017-05-03T11:50:49Z")

</div>

The problem with Google login is that after Lock 10.5 we dropped explicit support for electron in Auth0.js additionally google now blocks web views from logging in. This specific use-case falls under PKCE you can either use something like what I’m doing in [GitHub - darkyen/pkce-demos: A bunch of PKCE demos, using Auth0.js to extend the 🔐 to multiple providers!](https://github.com/darkyen/pkce-demos) (instead of listening to `open-url` you can create an express server and listen on it for callback) alternatively you can use [https://github.com/oidc/AppAuth-JS](https://github.com/oidc/AppAuth-JS) (they have an example in `/src/node_app`) with Auth0 as oidc provider and your client\_id as client\_id.

---

<div class="post-metadata">

**Author:** ![geoffrey](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@geoffrey](https://community.auth0.com/u/geoffrey)\
**Post date:** [May 3, 2017, 8:02pm UTC](https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441/3 "2017-05-03T20:02:45Z")

</div>

Thank you @abhishek.hingnikar.

I will look into both those solutions.

Cheers,  
Geoffrey

---

<div class="post-metadata">

**Author:** ![Abhishek\_Hingnikar1](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@Abhishek\_Hingnikar1](https://community.auth0.com/u/Abhishek_Hingnikar1)\
**Post date:** [May 3, 2017, 11:16pm UTC](https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441/4 "2017-05-03T23:16:40Z")

</div>

We re-added the handlers, you might be able to do this if your force popup mode (or redirect: false).

---

<div class="post-metadata">

**Author:** ![Abhishek\_Hingnikar1](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@Abhishek\_Hingnikar1](https://community.auth0.com/u/Abhishek_Hingnikar1)\
**Post date:** [May 4, 2017, 12:04am UTC](https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441/5 "2017-05-04T00:04:00Z")

</div>

There seems to be a bug with this approach though. We are working on it.

---

<div class="post-metadata">

**Author:** ![geoffrey](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@geoffrey](https://community.auth0.com/u/geoffrey)\
**Post date:** [May 4, 2017, 3:05am UTC](https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441/6 "2017-05-04T03:05:56Z")

</div>

Thank you.

If I can help, please let me know.

---

<div class="post-metadata">

**Author:** ![geoffrey](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@geoffrey](https://community.auth0.com/u/geoffrey)\
**Post date:** [May 5, 2017, 2:30am UTC](https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441/7 "2017-05-05T02:30:17Z")

</div>

Hi Abhishek,

I am looking at the PKCE demo approach.

First, nice slide deck. The information is clear and understandable even for someone as dense as me!

Second, are your comments about adding handlers and bug in the approach specific to PKCE or AppAuth-JS?

---

<div class="post-metadata">

**Author:** ![fawad](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@fawad](https://community.auth0.com/u/fawad)\
**Post date:** [October 18, 2017, 1:18am UTC](https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441/8 "2017-10-18T01:18:43Z")

</div>

**Repos** (updated)  
[https://github.com/faxad/cartify/blob/master/src/app/shared/auth.service.ts](https://github.com/faxad/cartify/blob/master/src/app/shared/auth.service.ts)

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [March 2, 2018, 5:53am UTC](https://community.auth0.com/t/google-connection-failing-in-electron-and-angular-4-with-lock-10-15/6441/9 "2018-03-02T05:53:37Z")

</div>


