react-native-qr-barcode
Version:
React Native WebView component of BarCode and QRCode
37 lines (28 loc) • 1.08 kB
Markdown
and QRCode.
Based on [chenchunyong/react-native-barCode](https://github.com/chenchunyong/react-native-barCode)
`npm i react-native-bar-qr-code --save`
```javascript
import {BarCode,QRCode} from 'react-native-qr-barcode'
/**
* value: Encrypted barcode text (default: '12345678901234567890')
* bgColor: Barcode background color (default: 'white')
* height: Barcode height (default: 90)
* width: Barcode width (default: 225)
*/
<BarCode
value={this.props.payCode}
bgColor="#e7e7eb"
/>
/**
* value: Encrypted QR code text (default: '12345678901234567890')
* bgColor: QR code background color (default: 'white')
* fgColor: QR code foreground color (default: 'black')
* size: QR code size (default: 128)
*/
<QRCode value={this.props.payCode}
fgColor="#333"/>
```
<img src="https://github.com/chenchunyong/react-native-barCode/raw/master/barCode.png" width = "375" height = "669" align=center />
React Native WebView component of BarCode