Primer home page
2.x.x-latest
Search...
⌘K
Ask AI
Contact Sales
Contact support
Contact support
Search...
Navigation
Types
HeadlessPaymentMethodButton
Home
Documentation
API Reference
SDK Reference
Connections
Changelogs
Web SDK
iOS SDK
Android SDK
React Native SDK
Web SDK
Getting started
Primer
PrimerCheckout
PrimerHeadlessCheckout
Methods
Types
HeadlessHostedInput
HeadlessPaymentMethodButton
CheckoutStyle
Common objects
Constants
Web SDK
PrimerHeadlessCheckout
Types
HeadlessPaymentMethodButton
The button instance returned by a
NativePaymentMethodManager’s
createButton
function
.
Hide Methods
render
(containerId: string, options: HeadlessButtonRenderOptions) => Promise<void>
Render the button inside a container with the given ID and options.
Show HeadlessButtonRenderOptions
style
Record<string, unknown>
The style options for the button.
setDisabled
(disabled: boolean) => Promise<void>
Set the disabled state of the button.
clean
() => void
Remove the button from the DOM.
focus
() => void
Set focus on the button.
blur
() => void
Remove focus from the button.
addEventListener
(event: EventTypes, callback: EventListener) => void
Add an event listener to the button.
Show Types
EventTypes
"blur" | "change" | "click" | "close" | "error" | "focus"
EventListener
(event?: Event) => void
HeadlessHostedInput
Overview
Assistant
Responses are generated using AI and may contain mistakes.