Skip to content

TomBrouws/capacitor-apple-login

 
 

Repository files navigation

Capacitor Apple Login

npm npm

Installation

  • npm i capacitor-apple-login

OR

  • npm i https://github.com/htorbov/capacitor-apple-login

Usage (iOS)

import { Plugins } from '@capacitor/core'

const { SignInWithApple } = Plugins

SignInWithApple.Authorize().then(response => {
  console.log(response)
}).catch(response => {
  console.error(response)
})

Instructions (Android/Web)

The plugin currently works for iOS only. It's made only to pass Apple's new terms. Add the Apple button only after you've checked that the user is on iOS device. If someone wants to implement Android/Web as well - all pull requests will be well welcomed :-)

const { Device } = Plugins

let device = await Device.getInfo()

if (device.platform === 'ios') {
  // Show the button with SignInWithApple.Authorize()
}

About

Capacitor Apple Login

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Swift 45.1%
  • Java 21.5%
  • Ruby 11.3%
  • TypeScript 10.2%
  • Objective-C 8.6%
  • JavaScript 3.3%