Open athoifss opened 3 years ago
It seems like upon re rendering (through prop change) the options object does not detect the new change and still renders the checkout with old props.
<PayPalButton options={{ clientId: clientID, currency: props.currency }} createOrder={createOrder} onApprove={onApprove} />
I did an ugly hack where I am forcefully re rendering the component on props.currency change. The component re renders all right but still with the previous options . The new props.currency is not being updated in checkout.
It seems like upon re rendering (through prop change) the options object does not detect the new change and still renders the checkout with old props.
I did an ugly hack where I am forcefully re rendering the component on props.currency change. The component re renders all right but still with the previous options . The new props.currency is not being updated in checkout.