react-payant

1.0.3 • Public • Published

react-payant

npm version

This is a react library for implementing payant payment inline js

Demo

React App

Get Started

This React library provides a wrapper to add Paystack Payments to your React application

Install

npm install react-payant --save

or with yarn

yarn add react-payant

Usage

import React, { Component } from "react";
//import the library
import Payant from "react-payant";
 
function App() {
  return (
    <Payant
      payantPublicKey={"<Your payant public key>"}
      client={{
        first_name: "Albert",
        last_name: "Jane",
        email: "jane@alberthospital.com",
        phone: "+2348012345678"
      }}
      due_date="12/30/2016"
      fee_bearer="client"
      items={[
        {
          item: ".Com Domain Name Registration",
          description: "alberthostpital.com",
          unit_cost: "2500.00",
          quantity: "1"
        }
      ]}
      callback={response => console.log(response)}
      close={() => console.log("closed")}
    />
  );
}
export default App;

Contributing

  1. Fork it!
  2. Create your feature branch: git checkout -b feature-name
  3. Commit your changes: git commit -am 'Some commit message'
  4. Push to the branch: git push origin feature-name
  5. Submit a pull request

How can I thank you?

Why not star the github repo? I'd love the attention! Why not share the link for this repository on Twitter or Any Social Media? Spread the word!

Don't forget to follow me on twitter!

Thanks! John Ayeni.

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Todo

  • Write tests

Package Sidebar

Install

npm i react-payant

Weekly Downloads

0

Version

1.0.3

License

MIT

Unpacked Size

71 kB

Total Files

8

Last publish

Collaborators

  • johnayeni