decode-html

2.0.0 • Public • Published

decode-html

  • decode html entities
  • tiny function that replaces the html entities for the chars: "<", ">", "''", "&"

install

npm install decode-html

use

var decode = require('decode-html');
 
console.log(decode('&lt;div class="hidden"&gt;NON&amp;SENSE&apos;s&lt;/div&gt;'));
// -> '<div class="hidden">NON&SENSE\'s</div>'
 

(opposite) encode function encode-html

test

npm test

license

MIT

author

Andi Neck | @andineck | intesso

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 2.0.0
    48,543
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 2.0.0
    48,543
  • 1.0.2
    944
  • 1.0.1
    3
  • 1.0.0
    2

Package Sidebar

Install

npm i decode-html

Weekly Downloads

26,190

Version

2.0.0

License

MIT

Last publish

Collaborators

  • andineck