id-applesigninplugin
TypeScript icon, indicating that this package has built-in type declarations

1.0.6 • Public • Published

IDAppleSignInPlugIn

This plugin let's you implement Apple SignIn into your Ionic application.

iOS plugin only

  • You need to add the Apple Signin capabilities to your Ionic project

Installation

npm install id-applesigninplugin

Usage example in a Ionic page:

import { Component } from '@angular/core';
import { Plugins } from "@capacitor/core";
const { IDAppleSignInPlugIn } = Plugins

@Component({
  selector: 'app-home',
  templateUrl: 'home.page.html',
  styleUrls: ['home.page.scss'],
})
export class HomePage {

  constructor() {}
     IDAppleSignInPlugIn.doAppleLogin().then((info)=>{
      if (info){
        console.log("on a info ")
        console.log(info)
        let identityTokenString = info["identityTokenString"]
        if (identityTokenString){
          console.log("on recoit "+identityTokenString)
        }
      }
      else{
        console.log("Pas de info")
      }
 
     })
}

API

IDAppleSignInPlugIn.doAppleLogin().then((info)=>{
    
})

You will get the sign in information in the info parameter:

Variables Description
user user identifier
email email user
identityTokenString Token identifier
...
Please refer to Apple documentation to know possible values
https://developer.apple.com/documentation/authenticationservices/asauthorizationappleidcredential

License

MIT

Free Software, Hell Yeah!

Readme

Keywords

Package Sidebar

Install

npm i id-applesigninplugin

Weekly Downloads

8

Version

1.0.6

License

MIT

Unpacked Size

256 kB

Total Files

81

Last publish

Collaborators

  • csurbier