vue-squarepay
v0.1.0
Published
A button component for sending HTTP requests to Square Payments API
Downloads
5
Maintainers
Readme
vue-squarepay
A Vue component that wraps the Web API functionality of Square to accept payments.
Install:
$ npm install --save vue-squarepay
Usage:
This component takes the query parameters to initiate a payment with the Squarepay WebAPI. The main settings are easily configurable with props : client, currency, amount, callbackUrl - see table below for full usage breakdown.
Params/Props:
Example:
Here is an example application containing the squarepay
component:
JavaScript:
import Vue from 'vue';
import Squarepay from 'vue-squarepay';
new Vue({
el: '#app',
store,
components: { Squarepay },
});
Markup:
<squarepay :callbackUrl="callbackUrl" :client="client" :currency="currency" :amount="amount"></squarepay>