1.0.2 • Published 4 months ago

qrpng v1.0.2

Weekly downloads
95
License
MIT
Repository
github
Last release
4 months ago

QR-PNG NPM

This is a very simple QR-Code generator that outputs a PNG-Buffer. It's written in pure JavaScript.

Usage

    import qrcode from 'qrpng;

    const uint8array = qrcode('my text for the code');
    document.getElementById('qrimg').src = 'image/png;base64,' + btoa(String.fromCharCode.apply(null, uint8array));

It has only one function:

function generate(content[, scale])

scale is the pixel extent of a QR-Code data pixel.

Install

npm install qrpng

License

This uses "QRCode for JavaScript" which Kazuhiko Arase thankfully MIT licensed. This modules is also licensed under MIT license.

1.0.2

4 months ago

1.0.1

4 years ago

1.0.0

4 years ago

0.1.2

10 years ago

0.1.1

11 years ago