@getmeru/pay-button
v0.0.28
Published
Button to allow payments from websites
Readme
Description
This package is intended to be used by our partners to allow payments in websites using Meru
Installation
If you are using a package manager
$ yarn add @getmeru/pay-buttonor
$ npm install @getmeru/pay-button --saveOr you can add it as a dependency in your html file
<script src="https://cdn.jsdelivr.net/npm/@getmeru/pay-button"></script>Usage
import Payment from "@getmeru/pay-button";
const meruPaymentButton = new Payment({
merchantId: "YOUR_MERCHANT_ID",
amount: 20.0,
onPaymentSuccess: () => {},
});
meruPaymentButton.render("meru-button-container");and just add this in the place where you want to render the button
<div id="meru-button-container"></div>