NativeScript / NativeScript/plugins

[@nativescript/google-signin]: Cannot read properties of undefined (reading 'activityResultEvent')

Open
#592 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
206
Forks
123
Avg merge
2d 1h
Merged PRs (30d)
1

Description

In runtime I am getting an error "Cannot read properties of undefined (reading 'activityResultEvent')" by clicking on button.

This is my code:
import { GoogleSignin } from '@nativescript/google-signin';

constructor() {
    GoogleSignin.configure() // called earlier in the app
}
  public signInApple(): void {
    GoogleSignin.signIn().then((user) => {
        console.log(user);
    },
    (err) => {
       console.log(err);
    });
}

In template:
<Button class="btn" (tap)="signInApple()">Sign in with Apple</Button>

@nativescript/google-signin version 2.0.6
Nativescript version 8.7.0, but tried with earlier versions.

Please help

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the error from the reported Button tap using @nativescript/google-signin 2.0.6 and NativeScript 8.7.0, then trace the GoogleSignin.configure() and GoogleSignin.signIn() entry points. Done means the reported activityResultEvent error no longer occurs and sign-in completes or reports a clear error.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.