Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
struct SignInWithAppleView: UIViewRepresentable {
@Binding var name : String
func makeCoordinator() -> Coordinator {
return Coordinator(self)
}
func makeUIView(context: Context) -> ASAuthorizationAppleIDButton {
let button = ASAuthorizationAppleIDButton(authorizationButtonType: .signIn, authorizationButtonStyle: .black)
button.addTarget(context.coordinator, action: #selector(Coordinator.didTapButton), for: .touchUpInside)
return button
}
func updateUIView(_ uiView: ASAuthorizationAppleIDButton, context: Context) {
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment