Skip to content

lljson.encode() should not encode NaN as illegal NaN literal #42

@HaroldCindy

Description

@HaroldCindy

Many JSON parsers support NaN literals, but JSON.parse() in JS environments does not. JSON.stringify([NaN]) returns [null], so just do that. lljson.slencode() is available for cases where we care about round-tripping.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions