alexeyten / qr-image

Yet another QR code generator
MIT License
1.05k stars 168 forks source link

how can I customize the png size? #15

Closed wanming closed 9 years ago

alexeyten commented 9 years ago

https://github.com/alexeyten/qr-image#options There is size option which set width and height of one square of image.

var qr = require('qr-image');

var qr_png = qr.image('I love QR!', { type: 'png', size: 10 });
qr_png.pipe(require('fs').createWriteStream('i_love_qr.png'));

You can't directly set size of result image because it's depend on length of text and error correction level.