npm.io
0.1.0 • Published 7 years ago

tiny-qr

Licence
MIT
Version
0.1.0
Deps
0
Size
126 kB
Vulns
0
Weekly
0

Wasm-powered QR code image generator

This library exposes two functions, typed accordingly:

// Encode binary data as PNG QR code
export function binary(data: Uint8Array): string | undefined;

// Encode string as PNG QR code
export function string(data: string): string | undefined;

The return value in both cases is a data URI string, ready to be used as a source for any image.