Opal-Estate-Pro/node_modules/safe-json-parse
2019-09-13 11:27:52 +07:00
..
examples style Dashboard 2019-09-13 11:27:52 +07:00
test style Dashboard 2019-09-13 11:27:52 +07:00
.npmignore style Dashboard 2019-09-13 11:27:52 +07:00
.testem.json style Dashboard 2019-09-13 11:27:52 +07:00
.travis.yml style Dashboard 2019-09-13 11:27:52 +07:00
index.js style Dashboard 2019-09-13 11:27:52 +07:00
LICENCE style Dashboard 2019-09-13 11:27:52 +07:00
package.json style Dashboard 2019-09-13 11:27:52 +07:00
README.md style Dashboard 2019-09-13 11:27:52 +07:00

safe-json-parse

build status dependency status

Parse JSON safely without throwing

Example

var safeParse = require("safe-json-parse")

safeParse("{}", function (err, json) {
    /* we have json */
})

safeparse("WRONG", function (err) {
    /* we have err! */
})

Installation

npm install safe-json-parse

Contributors

  • Raynos

MIT Licenced