Expression functionsType ConversionstoJSONOn this pagetoJSONThe value encoded as indented JSON text toJSON(x: any) -> string Arguments NameTypexany Example {{ toJSON({"id": 7}) }} Returns the JSON text, indented over several lines.