Skip to content

v3.0.0 You asked, we did

Compare
Choose a tag to compare
@Guria Guria released this 14 Nov 17:24
· 6 commits to master since this release

Features

loose escaping, ban undefined
undefined values are now omitted to avoid confusion when parsed back as strings.
It also aligns with JSON.stringify behavior.
Escaping rules is loosed to make output more readable.

change type symbol for objects from _ to $
Underscores is very popular to be a part of query both in keys and values.
Eg, see utm arguments for analytics tracking.
This changes allows parsing utm queries with urlon without extra escaping.

convert undefined in arrays to null
Skipping undefined in arrays breaks item indexes. This fix aligns behavior with JSON.stringify.

BREAKING

Stringify format changed. Parsing values generated by previous version isn't possible anymore.

Try new features on Runkit