JSON.minify icon indicating copy to clipboard operation
JSON.minify copied to clipboard

An empty object transforms to an empty string

Open lenchvolodymyr opened this issue 4 years ago • 0 comments

If you pass an empty object without carry line inside, the function returns an empty string, which fails JSON.parse.

To reproduce it you may run:

JSON.parse(jsonminify('{}'))

the expected output is '{}'

lenchvolodymyr avatar Feb 05 '20 14:02 lenchvolodymyr