react-qrcode-component
1.0.1 • Public • Published
npm install react-qrcode-component
yarn add react-qrcode-component
import React from 'react'
import ReactDOM from 'react-dom'
import QRCode from 'react-qrcode-component';
ReactDOM.render(
<QRCode value="https://github.com/liuyang1106/react-qrcode.git" />,
mountNode
);
value: '', // 需要转换的参数
size: 128, // 二维码大小
style: {}, // canvas样式
level: 'L',
bgColor: 'white',
fgColor: 'black',
scale: window.devicePixelRatio || 1, // 比例
Package Sidebar
Install
npm i react-qrcode-component
Weekly Downloads