Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zh/banano-pay-button
Easy to implement Banano payments via QR code.
https://github.com/zh/banano-pay-button
Last synced: 6 days ago
JSON representation
Easy to implement Banano payments via QR code.
- Host: GitHub
- URL: https://github.com/zh/banano-pay-button
- Owner: zh
- License: mit
- Created: 2020-06-18T23:07:01.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2023-01-06T09:18:48.000Z (almost 2 years ago)
- Last Synced: 2024-08-05T14:15:35.999Z (3 months ago)
- Language: JavaScript
- Size: 563 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 23
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
- banano-awesome - banano-pay-button - aasy to implement Banano currency payments via QR code. (Projects / Java)
README
Easy to implement Banano currency payments via QR code
## Description
The code allows adding Banano currency payments to any Web page by **including a single JavaScript file** and configuring the `
` container to host the button and the resulting QR code.## Usage
```html
```
## Container data options
All `data-` parameters are send to the underlaying React component. They are divided in two categories:
* **Banano URI** generation parameters:
* `data-title` - Text to be displayed on the button. *Optional*. *Default*: 'Pay with BAN'
* `data-address` - Banano address to send the payment. *Required*
* `data-amount` - Amount of Banano tokens. *Optional*
* `data-label` - Label for easy payment identification. *Optional*
* `data-info` - Add text information (address, amount and label) after the QR code. *Optional*
* **QR Code** configuration - all *data-qr-* parameters are optional:
* `data-qr-size` - QR code size. *Default:* 128
* `data-qr-level` - Error correction level. *Default:* 'M'
* `data-qr-fg` - QR code foreground. *Default:* '#000000'
* `data-qr-bg` - QR code background. *Default:* '#FFFFFF'## Available Scripts
In the project directory, you can run:
### `yarn start`
Runs the app in the development mode.
Open [http://localhost:8080](http://localhost:8080) to view it in the browser.
The page will reload if you make edits.
### `yarn build`
Builds the app for production to the `public` folder.
It correctly bundles React in production mode and optimizes the build for the best performance.The build is minified and your app is ready to be deployed!
*public/* directory contains all necessary files (*JavaScript* and *HTML*) so starting any web server (like for example *armor*) in that directory will allow examination of the result.