Version: 1.0.0
SubscriptionCreateModal
Used to make users pay for new subscriptions.
Loading...
info
SubscriptionCreateModal requires the product
and plan
to be set.
If you're using our default flow, the user selects those before moving to payment already.
But if you have your own custom flow, you can use the usePelcro hook to set them before switching to the payment view
like in the following example.
#
Usage#
Reference#
PropsonDisplay
#
() โ void
Callback function called when the modal is first displayed.
onClose
#
() โ void
Callback function called when the modal is closed.
onSuccess
#
(userObject) โ void
Callback function called when the user subscribes succesfully.
onFailure
#
(errorObject) โ void
Callback function called when the subscription creation fails.