
Security News
NIST Under Federal Audit for NVD Processing Backlog and Delays
As vulnerability data bottlenecks grow, the federal government is formally investigating NIST’s handling of the National Vulnerability Database.
TinyQRC is a lightweight and simple QR code generation library. Generate beautiful QR codes quickly and easily with zero dependencies.
npm install tinyqrc
# or
yarn add tinyqrc
# or
pnpm add tinyqrc
# or
bun add tinyqrc
import { generateSVG } from "tinyqrc";
// Generate a QR code
const svg = await generateSVG({
value: "https://example.com",
size: 256,
});
Generates a QR code as an SVG string.
type Options = {
value: string; // Content to encode
size?: number; // Size in pixels (default: 128)
level?: "L" | "M" | "Q" | "H"; // Error correction level (default: "L")
bgColor?: string; // Background color (default: "#FFFFFF")
fgColor?: string; // Foreground color (default: "#000000")
margin?: number; // Margin around QR code (default: 2)
imageSettings?: {
src: string; // URL of the image to embed
height?: number; // Image height
width?: number; // Image width
x?: number; // X position
y?: number; // Y position
excavate?: boolean; // Whether to clear QR code modules under the image
};
// Any additional SVG attributes are passed through to the root SVG element
};
L
: Low (7% of data can be restored)M
: Medium (15% of data can be restored)Q
: Quartile (25% of data can be restored)H
: High (30% of data can be restored)Note: When using imageSettings
with excavate: true
, the error correction level will automatically be increased to at least 'Q' to ensure better scannability.
Code Gen is based on nayuki/QR-Code-generator with modifications.
MIT License.
FAQs
A tiny QR code generator, written in TypeScript.
The npm package tinyqrc receives a total of 2 weekly downloads. As such, tinyqrc popularity was classified as not popular.
We found that tinyqrc demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
As vulnerability data bottlenecks grow, the federal government is formally investigating NIST’s handling of the National Vulnerability Database.
Research
Security News
Socket’s Threat Research Team has uncovered 60 npm packages using post-install scripts to silently exfiltrate hostnames, IP addresses, DNS servers, and user directories to a Discord-controlled endpoint.
Security News
TypeScript Native Previews offers a 10x faster Go-based compiler, now available on npm for public testing with early editor and language support.