Skip to content

zondezatera/react-native-promptpay-qr

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-native-promptpay-qr

NPM version react-native react node version npm download

Simple QR code for Promptpay in React native

Getting Started

Installation

npm i react-native-promptpay-qr --save

Basic Usage

import React, { Component } from 'react'
import { AppRegistry, View } from 'react-native'
import PromptPayQR from 'react-native-promptpay-qr'

class QRcode extends Component {
  render() {
    return (
        <View style={{flex: 1}}>
            <PromptPayQR
              payCode='081-xxx-xxxx'
              amount={200}
            />
        </View>
    )}
}

AppRegistry.registerComponent('PromptPayQR', () => PromptPayQR)

Properties


Props Type Default Description
payCode string - ID card number or Phone number ( 081-xxx-xxxx or 1-xxxx-xxxxx-xx-x )
amount number 0 quantity of pay
size number 128 size of qr code
bgColor string '#000' background of qr code
fgColor string '#FFF' foreground of qr code

References

License

react-native-promptpay-qr is released under the MIT license.