[TQRCode] deviceInfo가 없는경우
This commit is contained in:
@@ -45,6 +45,13 @@ export default function TQRCode({
|
||||
height: scaleH(height),
|
||||
correctLevel: window.QRCode.CorrectLevel.L,
|
||||
});
|
||||
} else if (typeof window === "object") {
|
||||
const qrcode = new window.QRCode(qrcodeRef.current, {
|
||||
text: `${text}`,
|
||||
width: scaleW(width),
|
||||
height: scaleH(height),
|
||||
correctLevel: window.QRCode.CorrectLevel.L,
|
||||
});
|
||||
}
|
||||
}, [text, deviceInfo]);
|
||||
return <div aria-label={ariaLabel} ref={qrcodeRef} />;
|
||||
|
||||
Reference in New Issue
Block a user