Skip to content

Simple remake of JSON.parser/.stringify that supports non-standard JSON parsing.

Notifications You must be signed in to change notification settings

manuelbarzi/not-json

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple remake of JSON.parse/.stringify that supports non-standard JSON parsing

Parses not-JSON like:

{ a: 1, b: "2", c: '3', "d": [1, "2", '3'] }

Installation:

$ npm i not-json

Usage:

var notJSON = require('not-json')

var obj = notJSON.parse('{ a: 1, b: "2", c: \'3\', "d": [1, "2", \'3\'] }')

console.log(obj)
// { a: 1, b: '2', c: '3', d: [ 1, '2', '3' ] }

var json = notJSON.stringify(obj)

console.log(json)
// {"a":1,"b":"2","c":"3","d":[1,"2","3"]}

About

Simple remake of JSON.parser/.stringify that supports non-standard JSON parsing.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published