Encode data lists and dicts automatically as JSON.