scholtz / qrcode-vue3

MIT License
87 stars 33 forks source link

QR Code size is not always the one specified? #43

Open RaileanuVlad opened 10 months ago

RaileanuVlad commented 10 months ago

I'm using the same html component/template to render different links as QR codes using this package, with a set width/height of 144, but depending on the link given the QR code is sometimes smaller than that, leaving a thick white outline. Is there any way to force/stretch out the QR code to always be the given size?

MeriMart commented 10 months ago

I have the same problem! I tried to force the size using "margin", but the margins don't change.

nicost71 commented 6 months ago

@RaileanuVlad Actually I had the same issue, and it took me quite some time to figure it out, but it actually depends on the url. If you have a long url (and e.g. many url-queries or the like) the qr-code gets more dense, thus if you set the height/width too small, it scales it, giving the (actually transparent) margin on the img.

You can try setting a higher width/height - at least this solved the issue for me..