Skip to content

Commit 172059f

Browse files
Only allow paypal button for standard paypal checkout (#1287)
1 parent 1ef6c66 commit 172059f

2 files changed

Lines changed: 11 additions & 1 deletion

File tree

.changeset/dirty-lions-serve.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@godaddy/react": patch
3+
---
4+
5+
Limit paypal express to paypal button only

packages/react/src/components/checkout/payment/checkout-buttons/paypal/paypal.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
import { PayPalButtons, usePayPalScriptReducer } from '@paypal/react-paypal-js';
1+
import {
2+
FUNDING,
3+
PayPalButtons,
4+
usePayPalScriptReducer,
5+
} from '@paypal/react-paypal-js';
26
import { useState } from 'react';
37
import { useFormContext } from 'react-hook-form';
48
import { useCheckoutContext } from '@/components/checkout/checkout';
@@ -88,6 +92,7 @@ function PayPalButtonsWrapper() {
8892

8993
return (
9094
<PayPalButtons
95+
fundingSource={FUNDING.PAYPAL}
9196
style={{
9297
layout: 'vertical',
9398
label: 'pay',

0 commit comments

Comments
 (0)