Skip to content

Latest commit

 

History

History
30 lines (18 loc) · 1.31 KB

README.md

File metadata and controls

30 lines (18 loc) · 1.31 KB

Vue App PayPal Integration

Get started

Install the dependencies...

cd vue-integration
npm install

...log in to the developer dashboard and get your client ID from your default application. Change const CLIENT_ID = 'your-client-id'; in src/components/CheckoutPayment.vue so CLIENT_ID matches your sandbox client ID...

If you need help setting up your developer dashboard or finding your client ID, follow the first step in the getting started documentation to get API credentials

...then start:

npm run dev

Navigate to localhost:5173. You should see the app running.

How It Works

The JavaScript SDK is imported via paypal-js in src/components/Checkout.vue where we set up a div to hold the buttons. Style, payment method, and other options can be specified in paypal.Buttons()

Further help

For more details and configuration options look at paypal-js usasge and the PayPal JavaScript SDK Complete Reference