</>PackageGraphPackageGraph

html-encoding-sniffer

npmv6.0.0

Sniff the encoding from a HTML byte stream

Safe to adopt

Yes — html-encoding-sniffer scores well across adoption, maintenance, weight, supply chain, and licensing. No download data reported for this package yet. Last published 258 days ago. 2 releases in the last 2 years.

  • ?Adoption: grade ?, Not reported by this registry.

    No download data reported for this package yet.

  • BMaintenance: grade B, Good.

    Last published 258 days ago. 2 releases in the last 2 years.

  • AWeight: grade A, Excellent.

    Pulls in 1 transitive package, about 432 KB installed.

  • ASupply chain: grade A, Excellent.

    No install scripts, 6 maintainers, and a contained dependency surface.

  • ALicense: grade A, Excellent.

    MIT — permissive, with no copyleft found in the dependency tree.

Grades are computed deterministically from registry metadata collected by PackageGraph — downloads, dependents, publish dates, the resolved dependency tree, maintainer count, and declared licenses. No third-party scores are used.

Install cost

What you actually take on by adding html-encoding-sniffer to a project.

1
Direct dependencies

Runtime packages this one declares itself.

1
Total installed

Distinct packages in the full runtime tree, deduplicated the way a package manager would.

432 KB
Install size

Unpacked size of this package plus its entire runtime tree.

1
Tree depth

Longest resolved dependency chain below this package.

Licenses in the dependency tree

MIT

Every license you inherit by installing html-encoding-sniffer, not just its own. Check this before a legal review, not after.

Compatibility

Node.js
node ^20.19.0 || ^22.12.0 || >=24.0.0
Module format
CommonJS only
TypeScript
No bundled types
Install scripts
None

Quick start

A usage example from the html-encoding-sniffer README.

const htmlEncodingSniffer = require("html-encoding-sniffer");
const fs = require("fs");

const htmlBytes = fs.readFileSync("./html-page.html");
const sniffedEncoding = htmlEncodingSniffer(htmlBytes);

html-encoding-sniffer vs the alternatives

Packages solving a similar problem in the npm ecosystem, compared on the signals that drive an adoption decision.

PackageWeekly downloadsDependentsLicenseLast release
html-encoding-snifferthis page01MIT8 months ago
dom-serializer94.3M2MIT1 day ago
html-escaper79.8M1MIT1 day ago
is-potential-custom-element-name41.4M2MIT1 day ago
cheerio24.1M5MIT1 day ago
anser10.4M3MIT1 day ago

Dependencies

Declared by html-encoding-sniffer v6.0.0. Runtime dependencies are installed with the package; dev dependencies are not.

Dev (3)

@domenic/eslint-config ^4.0.1eslint ^9.39.2globals ^16.5.0

Used by

Popular packages that depend on html-encoding-sniffer.

Relationship graph

Dependencies (left) and dependents (right) of html-encoding-sniffer.

@exodus/bytesjsdomhtml-encoding-sni…
html-encoding-sniffer dependencies dependents

Frequently installed together

whatwg-urlnpm

An implementation of the WHATWG URL Standard's URL API and parsing machinery

204.4M/wk3 dependentsMIT
undicinpm

An HTTP/1.1 client, written from scratch for Node.js

158.5M/wk15 dependentsMITTS
eslintnpm

An AST-based pattern checker for JavaScript.

138.4M/wk279 dependentsMITTS
is-potential-custom-element-namenpm

Check whether a given string matches the `PotentialCustomElementName` production as defined in the HTML Standard.

41.4M/wk2 dependentsMIT
decimal.jsnpm

An arbitrary-precision Decimal type for JavaScript.

0/wk1 dependentsMITTS
webidl-conversionsnpm

Implements the WebIDL algorithms for converting to and from JavaScript values

0/wk2 dependentsBSD-2-Clause
whatwg-mimetypenpm

Parses, serializes, and manipulates MIME types, according to the WHATWG MIME Sniffing Standard

0/wk3 dependentsMIT
@asamuzakjp/css-colornpm

CSS color - Resolve and convert CSS colors.

0/wk1 dependentsMITTS
w3c-xmlserializernpm

A per-spec XML serializer implementation

0/wk1 dependentsMIT
xml-name-validatornpm

Validates whether a string matches the production for an XML name or qualified name

0/wk2 dependentsApache-2.0
@csstools/css-syntax-patches-for-csstreenpm

CSS syntax patches for CSS tree

0/wk1 dependentsMIT-0TS
css-treenpm

A tool set for CSS: fast detailed parser (CSS → AST), walker (AST traversal), generator (AST → CSS) and lexer (validation and matching) based on specs and browser implementations

0/wk5 dependentsMIT

Release history

2 releases in the last two years, typically about 573 days apart.

Recent versions of html-encoding-sniffer
VersionPublishedSizeLicense
6.0.0latest8 months ago12 KBMIT
5.0.08 months ago12 KBMIT
4.0.02 years ago11 KBMIT
3.0.05 years ago11 KBMIT
2.0.16 years ago11 KBMIT
2.0.06 years ago11 KBMIT
1.0.29 years agoMIT
1.0.110 years agoWTFPL
1.0.010 years agoWTFPL

Overview

html-encoding-sniffer is an npm package that sniff the encoding from a HTML byte stream. It has 1 known dependents in the graph. The latest version is 6.0.0, released under the MIT license.

Who should use it

Teams working in the npm ecosystem who need sniff the encoding from a HTML byte stream and value a focused solution.

When not to use it

Consider an alternative if you need to have first-class TypeScript types out of the box, or if a more actively-maintained option better fits your npm stack.

Pros

  • Clear open-source license (MIT).

Cons

  • No bundled TypeScript types (may require a separate @types package).

Auto-generated from collected registry metadata. No external claims are inferred.

Maintainers

Keywords

Frequently asked questions

Should I use html-encoding-sniffer?

Yes — html-encoding-sniffer scores well across adoption, maintenance, weight, supply chain, and licensing. No download data reported for this package yet. Last published 258 days ago. 2 releases in the last 2 years.

How do I install html-encoding-sniffer?

Run `npm install html-encoding-sniffer` to add html-encoding-sniffer to your npm project.

How many dependencies does html-encoding-sniffer have?

html-encoding-sniffer declares 4 direct dependencies and pulls in 1 packages in total once its runtime tree is resolved totalling about 432 KB on disk.

What license is html-encoding-sniffer released under?

html-encoding-sniffer is distributed under the MIT license.

How popular is html-encoding-sniffer?

npm does not publish download counts. Within PackageGraph's crawl, 1 known packages depend on html-encoding-sniffer.

Is html-encoding-sniffer still maintained?

The most recent release of html-encoding-sniffer (v6.0.0) was published 8 months ago.

Does html-encoding-sniffer run install scripts?

No. html-encoding-sniffer does not define preinstall, install, or postinstall scripts, so installing it does not execute publisher-supplied code.