1.3.15 • Published 28 days ago
pgqr v1.3.15
PGQR
A QR Code generator with full logo + svg support
Usage
npm install pgqr
import {PGQRCode} from 'pgqr';
const options = {
errorCorrectionLevel: 'H',
maskPattern: undefined,
logoScale: 0.9,
logoAreaScale: 1,
dotRadius: 0.5,
dotScale: 0.95,
dotColor: 'black',
outerEyeRadius: 0.5,
outerEyeColor: 'black',
innerEyeRadius: 0.5,
innerEyeColor: 'black',
backgroundColor: 'red'
}
const qr = new PGQRCode();
const svgString = await qr.renderSVG('https://example.com', options, '/logo.svg');
const pngBlob = await qr.toImage('https://example.com', options, '/logo.svg', 1024, 'png');
const jpgBlob = await qr.toImage('https://example.com', options, '/logo.svg', 1024, 'jpg');
const svgBlob = await qr.toSvg('https://example.com', options, '/logo.svg');
const pdfBlob = await qr.toPDF('https://example.com', options, '/logo.svg');
const zipBlob = await qr.toBatch(
[
{code: 'https://example.com', filename: 'qr1'},
{code: 'https://example.com', filename: 'qr2'},
{code: 'https://example.com', filename: 'qr3'},
],
options,
'/logo.svg',
1024,
formats: ['png', 'jpg', 'svg', 'pdf']
);
Road Map
- More dot styles
- Triangle, Diamond, Circle, Hexagon etc
- Import custom SVG
1.3.14
28 days ago
1.3.15
28 days ago
1.3.13
1 month ago
1.3.7
1 month ago
1.3.6
1 month ago
1.3.5
1 month ago
1.3.4
1 month ago
1.3.3
1 month ago
1.3.2
1 month ago
1.3.10
1 month ago
1.3.11
1 month ago
1.3.12
1 month ago
1.3.9
1 month ago
1.3.8
1 month ago
1.3.1
1 month ago
1.2.9
1 month ago
1.2.8
1 month ago
1.2.7
1 month ago
1.1.6
1 month ago
1.1.5
1 month ago
1.1.4
1 month ago
1.1.3
1 month ago
1.1.2
1 month ago
1.1.0
1 month ago
1.0.9
1 month ago
1.0.8
1 month ago
1.0.7
1 month ago
1.0.6
1 month ago
1.0.5
1 month ago
1.0.4
1 month ago
1.0.3
1 month ago
1.0.2
1 month ago
1.0.1
1 month ago
1.0.0
1 month ago