UNPKG

square-react-form

Version:

This is Square-React-form which has all the front-end/UI is configured.

38 lines (25 loc) 1.09 kB
This is Square-React-form which has all the front-end/UI is configured. This app will create a nonce for a card and this nonce should be sent to the Square backend server which needs to be configured by yourself. U can give a url link(in which Square server is there) through props which will make a request to that server and makes the payment. The payment amount should be configured in the backend Square server. npm install square-react-form -----> Example ```javascript import React, { Component } from "react"; import "./App.css"; import { SquareForm } from "square-react-form"; class App extends Component { render() { return ( <div> <h1>Square checkout Form!</h1> <br /> <SquareForm url="https://*/*"/> </div> ); } } export default App; ``` ---> The front-end code for this can be found => https://github.com/mootrichard/square-react-online-payments I have took the code from that repo and made it into this package. There are some issues which will be resolved in future updates.