You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to save payment methods for future use without an immediate transaction using the PayPalCardFieldsProvider component. This component does not allow to call only the createVaultSetupToken prop because the createOrder prop is mandatory.
I tried to specify both functions (createVaultSetupToken and createOrder) but there is an error shown in the console.
Error in console when trying to use createVaultSetupToken with PayPalCardFieldsProvider component even though its available in the provided interface.
🔬 Minimal Reproduction
Add a PayPalCardFieldsProvider component and try to add the createVaultSetupToken prop without createOrder or try to add both createVaultSetupToken and createOrder.
😕 Actual Behavior
When trying to specify only createVaultSetupToken :
When trying to specify both createVaultSetupToken and createOrder: Error is thrown during runtime : Uncaught Error: Cannot pass both createVaultSetupToken and createOrder
🤔 Expected Behavior
Being able to use the createVaultSetupToken prop in PayPalCardFieldsProvider component without having to specify a createOrder prop.
🌍 Environment
Node.js/npm: - 20.14.0
OS: - Windows 11
Browser: - Edge
➕ Additional Context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
Library used
react-paypal-js
🐞 Describe the Bug
I want to save payment methods for future use without an immediate transaction using the
PayPalCardFieldsProvider
component. This component does not allow to call only thecreateVaultSetupToken
prop because thecreateOrder
prop is mandatory.I tried to specify both functions (createVaultSetupToken and createOrder) but there is an error shown in the console.
Error in console when trying to use
createVaultSetupToken
withPayPalCardFieldsProvider
component even though its available in the provided interface.🔬 Minimal Reproduction
Add a
PayPalCardFieldsProvider
component and try to add thecreateVaultSetupToken
prop withoutcreateOrder
or try to add bothcreateVaultSetupToken
andcreateOrder
.😕 Actual Behavior
When trying to specify only
createVaultSetupToken
:When trying to specify both
createVaultSetupToken
andcreateOrder
: Error is thrown during runtime :Uncaught Error: Cannot pass both createVaultSetupToken and createOrder
🤔 Expected Behavior
Being able to use the
createVaultSetupToken
prop inPayPalCardFieldsProvider
component without having to specify acreateOrder
prop.🌍 Environment
➕ Additional Context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: