GitHub
461
Created 2 years ago, last commit 2 years ago
2 contributors
16 commits
Stars added on GitHub, month by month
0
5
6
7
8
9
10
11
12
1
2
3
4
2024
2025
Stars added on GitHub, per day, on average
Yesterday
=
Last week
0.0
/day
Last month
0.0
/day
Last 12 months
+0.1
/day
npmPackage on NPM
Monthly downloads on NPM
5
6
7
8
9
10
11
12
1
2
3
4
2024
2025
No dependencies
README

headless-qr

A simple, modern QR code generator. Adapted from https://github.com/kazuhikoarase/qrcode-generator but without all the junk that was necessary 10 years ago.

Usage

import { qr } from 'headless-qr';

// generate an n x n array of booleans,
// where `true` is a dark pixel
const modules = qr('https://example.com');

// specify version and error correction
const modules = qr('https://example.com', {
	version: 40, // 1 - 40, will select the best version if unspecified
	correction: 'Q' // L, M, Q or H
});