We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
展码这样的需求场景十分常见,在二维码生成之后需要根据移动设备的宽高写自适应。但是问题来了,使用到的qrcodejs2,构造函数传入的宽高不是rem这样的单位。canvas的画布大小是固定的。为此使用曲线救国在生成二维码的节点下加入important样式。
img, canvas { width: 3.8rem !important; height: 3.8rem !important; }
这样就可以实现二维码的自适应。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
展码这样的需求场景十分常见,在二维码生成之后需要根据移动设备的宽高写自适应。但是问题来了,使用到的qrcodejs2,构造函数传入的宽高不是rem这样的单位。canvas的画布大小是固定的。为此使用曲线救国在生成二维码的节点下加入important样式。
这样就可以实现二维码的自适应。
The text was updated successfully, but these errors were encountered: