safeson

1.0.0 • Public • Published

safeson

Convert JSON to something you can safely embed in HTML

Install

You can get it on npm.

npm install safeson --save

Usage

safeson(data, spaces?)

Takes data, turns it into JSON, and strips away HTML hazards

safeson.decode(data)

Takes data previously encoded with safeson and unescapes it, then turns it into an object

License

MIT

Readme

Keywords

none

Package Sidebar

Install

npm i safeson

Weekly Downloads

407

Version

1.0.0

License

MIT

Last publish

Collaborators

  • bevacqua