文档网址:https://www.npmjs.com/package/qrcode.react
1 安装
yarn add qrcode.react
2 导入
import QRCode from "qrcode.react"
3 使用
<QRCode
value={`${api.links}invite?name=${ qrname }&agentId=${qrid}`} //value 参数为生成二维码的链接
size={100} //二维码的宽高尺寸
fgColor="#000" //二维码的颜色
/>