# tsayen/dom-to-image

Generates an image from a DOM node using HTML5 canvas

Repository: https://github.com/tsayen/dom-to-image
Canonical: https://ross.abutalabs.com/products/dom-to-image
Language: JavaScript
License: NOASSERTION
License Family: other
Topics: canvas, html, dom, render, image, raster, vector, javascript, css, svg
Last push: 2024-04-08T16:26:47+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 4156, "days_push": 877, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases, no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 10779, forks 1680 (observed 2026-08-28T04:10:44.248398+00:00)

## What it is
A JavaScript library that converts arbitrary DOM nodes into vector (SVG) or raster (PNG/JPEG) images using HTML5 canvas and SVG serialization. It supports web fonts, images, node filtering, and raw pixel data extraction.

## Use cases
- render a DOM element to a PNG image in the browser
- export an HTML chart or widget as a downloadable JPEG
- convert a DOM node to an SVG data URL
- capture a screenshot of a page section client-side
- get raw RGBA pixel data from rendered HTML

## When to choose
- you need client-side rendering of HTML to images without a headless browser
- you want to export charts, cards, or UI components as PNG/JPEG/SVG
- you need pixel data from rendered DOM content

## When to avoid
- you need pixel-perfect full-page screenshots with full CSS support (use Puppeteer or Playwright)
- you need server-side rendering of HTML to images
- the project appears largely unmaintained; consider actively maintained forks like html-to-image

## Facets
- artifact type: library
- maturity: maintenance
- function: image-processing, graphics
- domain: web-development, frontend
- platform: browser
- tags: dom, canvas, svg, screenshot, png, jpeg, html-to-image, nodejs

## Member repositories
- tsayen/dom-to-image (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:10:44.248398+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:17:52.412865+00:00, confidence not recorded.
  - readme: https://github.com/tsayen/dom-to-image (fetched 2026-08-28T04:10:44.248398+00:00, sha 58d9fbac426f)
  - registry_npm: https://registry.npmjs.org/dom-to-image (fetched 2026-08-29T08:17:07.371374+00:00, sha bc4ea0a69f8a)
- Data as of 2026-08-30T08:39:29.467469+00:00.
