Transforms a Map into a JSON string. Transforms strings, numbers, booleans,
and null as expected; maps become nested objects; arrays and collections
(list, set, whatever) become arrays; dates become strings formatted as
ISO-8601 timestamps; anything else is converted to a string.