1.2.3 • Published 4 years ago

react-seerbit v1.2.3

Weekly downloads
2
License
MIT
Repository
github
Last release
4 years ago

react-seerbit

Seerbit react API

Get Started

A simple way to add Seerbit Payments to your React application

NPM JavaScript Style Guide

Install

npm install --save react-seerbit

Usage

import React, { Component } from "react";

import SeerbitPay from "react-seerbit";

export default class App extends Component {
  constructor(props) {
    super(props);
    this.state = {
      public_key: "YOUR_API_KEY",
      amount: 100,
      tranref: new Date().getTime(),
      customization: {
        theme: {
          border_color: "#000000",
          background_color: "#004C64",
          button_color: "#0084A0",
        },
        payment_method: ["card", "account", "transfer", "wallet"],
        display_fee: true, // true 
        display_type: "embed", //inline
        logo: "logo_url | base64", 
      }
    };
  }

  close = (close) => {
    console.log(close);
  };
  callback = (response) => {
    console.log(response);
  };
  render() {
    return (
      <SeerbitPay
        className="btn seerbit-btn"
        tranref={this.state.tranref}
        currency={"NGN"}
        description={"test"}
        country={"NG"}
        clientappcode="app1"
        public_key={this.state.public_key}
        callback={this.callback}
        close={this.close}
        amount={this.state.amount}
        tag={"button"}
        full_name={"John Doe"}
        email={"a@b.com"}
        mobile_no={"00000000000"}
        customization={this.state.customization}
        version={"v1"}
      />
    );
  }
}

Please checkout Seerbit Documentation for other available options you can add to the tag

License

MIT © tosyngy

1.2.3

4 years ago

1.2.2

4 years ago

1.2.1

4 years ago

1.2.0

4 years ago

1.1.0

5 years ago

1.0.9

5 years ago

1.0.8

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago