npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@qrcodesdk/node

v0.0.5

Published

@qrcodesdk/node adds renderers that depend on Node.js APIs or server-side packages. Use it with `@qrcodesdk/core` when your output needs to be PNG bytes.

Readme

@qrcodesdk/node

Open @qrcodesdk/node on npmx.dev @qrcodesdk/node version @qrcodesdk/node install size @qrcodesdk/node download/mo @qrcodesdk/node source code

Documentation | Live Demo

Node.js renderers for QRCodeSDK. Use this package with @qrcodesdk/core when you need a PNG, WebP, GIF, or JPEG Buffer for files, HTTP responses, downloads, email attachments, or other server-side integrations.

Install

npm install @qrcodesdk/core @qrcodesdk/node
pnpm add @qrcodesdk/core @qrcodesdk/node

vp

vp add @qrcodesdk/core @qrcodesdk/node

deno

deno add @qrcodesdk/core @qrcodesdk/node

bun

bun add @qrcodesdk/core @qrcodesdk/node

yarn

yarn add @qrcodesdk/core @qrcodesdk/node

Minimal example

import {qrcode} from '@qrcodesdk/core';
import {QRCodePNGRenderer} from '@qrcodesdk/node';

const png = qrcode('https://qrcodesdk.dev').render(QRCodePNGRenderer());

QRCodePNGRenderer() returns a Node.js Buffer containing a square PNG image. RGB and RGBA style colors are preserved, including transparent backgrounds.

Choose a format

| Format | Renderer | Content-Type | Choose it when | | ------ | -------------------- | -------------- | ----------------------------------------------------------------- | | PNG | QRCodePNGRenderer | image/png | The destination needs the most widely supported raster format | | WebP | QRCodeWebPRenderer | image/webp | The destination accepts WebP and file size matters | | GIF | QRCodeGIFRenderer | image/gif | The destination only accepts GIF | | JPEG | QRCodeJPEGRenderer | image/jpeg | The destination only accepts JPEG, or the center image is a photo |

All four renderers draw the same pixels from the same style and centerImage options and return a Buffer. WebP output is lossless and usually much smaller than PNG; a default QR code for https://qrcodesdk.dev is about 310 bytes as WebP and 1.1 KB as PNG. GIF output is a single frame with at most 256 colors and binary transparency: pixels below transparency.threshold alpha become transparent and all others opaque. JPEG output is lossy and has no transparency: transparent pixels are blended onto transparency.matte, white by default. It is about 9.7 KB for the same QR code, or 870 bytes with a module size of 8, so use it only when the destination requires JPEG or a photographic center image benefits from it.

import {qrcode} from '@qrcodesdk/core';
import {QRCodeGIFRenderer, QRCodeJPEGRenderer, QRCodeWebPRenderer} from '@qrcodesdk/node';

const builder = qrcode('https://qrcodesdk.dev');
const webp = builder.render(QRCodeWebPRenderer());
const gif = builder.render(QRCodeGIFRenderer());
const jpeg = builder.render(QRCodeJPEGRenderer({quality: 90}));

Work with raster output

See the PNG, WebP, GIF, and JPEG Buffer renderers for their options and exact constraints. Center images created with rasterCenterImage() from PNG bytes work with all four renderers. Follow Download or save to write a Buffer to disk or Serve a QR code to return it with its media type.

Runtime requirements

@qrcodesdk/node directly supports Node.js 22.0.0 or newer. Bun and Deno are supported through their Node.js compatibility layers.

The public TypeScript API uses Node's global Buffer type. TypeScript consumers must include @types/node in their development dependencies and make Node types available in their TypeScript options.

Public API

import {
  QRCodeGIFRenderer,
  type QRCodeGIFRendererOptions,
  QRCodeJPEGRenderer,
  type QRCodeJPEGRendererOptions,
  QRCodePNGRenderer,
  type QRCodePNGRendererOptions,
  type QRCodeRasterCenterImage,
  type QRCodeRasterRendererOptions,
  QRCodeWebPRenderer,
  type QRCodeWebPRendererOptions,
  rasterCenterImage,
} from '@qrcodesdk/node';

Documentation