entities-dom-decode
TypeScript icon, indicating that this package has built-in type declarations

2.0.0 • Public • Published

Entities DOM Decode

A ~200 bytes function with no dependencies for decoding HTML entities, it only works in the browser.

Features

  • Every other package for decoding HTML entities ships with a ~30kb list of entities supported, this package doesn't need such list as it uses the DOM for decoding entities, and it's as a result ~99% smaller. The downside is that it only works in the browser.

Install

npm install --save entities-dom-decode

Usage

import decode from 'entities-dom-decode';

decode ( '&:' ); // => '&:'

License

MIT © Fabio Spampinato

/entities-dom-decode/

    Package Sidebar

    Install

    npm i entities-dom-decode

    Weekly Downloads

    3

    Version

    2.0.0

    License

    none

    Unpacked Size

    4.7 kB

    Total Files

    9

    Last publish

    Collaborators

    • fabiospampinato