PaymentButton
public struct PaymentButton<Content> : View where Content : View
A button which presents a sheet for a customer to complete their payment. This is a convenience wrapper for the .paymentSheet() ViewModifier.
Parameters
paymentSheet
|
A PaymentSheet to present. |
onCompletion
|
Called with the result of the payment after the payment sheet is dismissed. |
content
|
The content of the view. |
-
Initialize a
PaymentButton
with required parameters.Declaration
Swift
public init( paymentSheet: PaymentSheet, onCompletion: @escaping (PaymentSheetResult) -> Void, @ViewBuilder content: () -> Content )
-
Declaration
Swift
public var body: some View { get }