Skip to content

We always want to comment in json but result in invalid json format in JSON.parse. However with remove-json-comments, nothing is impossible.

License

Notifications You must be signed in to change notification settings

git-patrickliu/remove-json-comments

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

remove-json-comments Build Status

We always want to comment in json but result in invalid json format in JSON.parse. However with remove-json-comments, you can do it.

usage

$ npm install remove-json-comments --save
var removeJsonComments = require('remove-json-comments');
var string = '/* haha */{"hello": "world"}';
console.log(JSON.parse(removeJsonComments(string));

About

We always want to comment in json but result in invalid json format in JSON.parse. However with remove-json-comments, nothing is impossible.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published