JSON and folding