html-entities
Advanced tools
Comparing version 1.0.0 to 1.0.1
{ | ||
"name": "html-entities", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "Faster HTML entities encode/decode library.", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
node-html-entities | ||
================== | ||
Faster html entities library | ||
Faster html entities library. | ||
Installation | ||
------------ | ||
npm install html-entities | ||
Usage | ||
----- | ||
####Basic HTML entities#### | ||
HTML validity and XSS attack prevention you can achieve from BasicHtmlEntities class. | ||
```javascript | ||
var Entities = require('html-entities').BasicHtmlEntities; | ||
entities = new Entities(); | ||
console.log(entities.encode('<>"&©®')); // <>"&©® | ||
console.log(entities.decode('<>"&©®')); // <>"©® | ||
``` | ||
####Full HTML entities encoding/decoding#### | ||
```javascript | ||
var Entities = require('html-entities').FullHtmlEntities; | ||
entities = new Entities(); | ||
console.log(entities.encode('<>"&©®')); // <>"&©® | ||
console.log(entities.decode('<>"&©®')); // <>"&©® | ||
``` |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7214
39