deep-escape-html
v0.1.0
Published
Deeply escape object's string properties for use in HTML
Downloads
3
Readme
deep-escape-html
Deeply escape object's string properties for use in HTML. Build on top escape-html.
Example
var escape = require('deep-escape-html')
var html = escape({a: "<script>alert('PWNED')</script>", {b: ['<div></div>', 1, true, false]}})
// -> {a: '<script>alert('PWNED')</script>', {b: ['<div></div>', 1, true, false]}}
License
MIT