Serialize a value to JSON with object keys sorted recursively.
Two values that are logically equal but have different key insertion order
produce the same output string, making this suitable for content-addressed hashing.
Arrays preserve their original element order.
Serialize a value to JSON with object keys sorted recursively. Two values that are logically equal but have different key insertion order produce the same output string, making this suitable for content-addressed hashing. Arrays preserve their original element order.