Skip to content

Latest commit

 

History

History
76 lines (55 loc) · 2.07 KB

StripeV3PaymentInitializeOptions.md

File metadata and controls

76 lines (55 loc) · 2.07 KB

@bigcommerce/checkout-sdk / StripeV3PaymentInitializeOptions

Interface: StripeV3PaymentInitializeOptions

A set of options that are required to initialize the Stripe payment method.

Once Stripe payment is initialized, credit card form fields, provided by the payment provider as iframes, will be inserted into the current page. These options provide a location and styling for each of the form fields.

<!-- This is where the credit card component will be inserted -->
<div id="container"></div>
service.initializePayment({
    methodId: 'stripev3',
    stripev3: {
        containerId: 'container',
    },
});

Additional options can be passed in to customize the fields.

service.initializePayment({
    methodId: 'stripev3',
    stripev3: {
        containerId: 'container',
        options: {
            card: {
                classes: { base: 'form-input' },
            },
            iban: {
                classes: { base: 'form-input' },
                supportedCountries: ['SEPA'],
            },
            idealBank: {
                classes: { base: 'form-input' },
            },
        },
    },
});

Table of contents

Properties

Properties

containerId

containerId: string

The location to insert the credit card number form field.


form

Optional form: HostedFormOptions

Hosted Form Validation Options


options

Optional options: CardCvcElementOptions | CardElementOptions | CardExpiryElementOptions | CardNumberElementOptions | IbanElementOptions | IdealElementOptions | IndividualCardElementOptions | ZipCodeElementOptions