Capacitor plugin to support Sign in With Apple
Maintainer | GitHub | Social | Sponsoring Company |
---|---|---|---|
Max Lynch | mlynch | @maxlynch | Ionic |
Maintenance Status: Partially Maintained (help wanted)
npm i @capacitor-community/apple-sign-in
import { Plugins } from '@capacitor/core'
import { ResponseSignInWithApplePlugin } from '@capacitor-community/apple-sign-in';
const { SignInWithApple } = Plugins
try {
const response: ResponseSignInWithApplePlugin = await SignInWithApple.Authorize()
} catch (e) {
}
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. Web support is planned for Apple's JS support (help wanted!).
const { Device } = Plugins
let device = await Device.getInfo()
if (device.platform === 'ios') {
// Show the button with SignInWithApple.Authorize()
}
Thanks goes to these wonderful people (emoji key):
Masahiko Sakakibara 💻 |
This project follows the all-contributors specification. Contributions of any kind welcome!