twogate / cordova-plugin-sign-in-with-apple

A native-implemented plugin of Sign in with Apple // Thanks to your contribution! // Cordova>=8 iOS>=13
https://www.npmjs.com/package/cordova-plugin-sign-in-with-apple
MIT License
74 stars 48 forks source link

TypeError: Object(...) is not a function at SignInWithAppleOriginal.signin #44

Open moisesgzmn opened 1 year ago

moisesgzmn commented 1 year ago

When i try to log in with apple, i get that error. My code:

async loginWithApple(): Promise<void> {

    try {
      const appleCredential: AppleSignInResponse = await SignInWithApple.signin({
        requestedScopes: [
          ASAuthorizationAppleIDRequest.ASAuthorizationScopeFullName,
          ASAuthorizationAppleIDRequest.ASAuthorizationScopeEmail
        ]
      });

      console.log({ appleCredential });

      alert(JSON.stringify(appleCredential))

    } catch (error) {
      console.log(error);
    }

  }