I'm facing an issue with my json file formatting. When I run clang-format on it, the output is ugly as it treats it like code.
{
"name" : "My great app",
"description" : "It's really cool.",
"version" : "0.0.1"
}
However, if I add 'foo = ' at the beginning of the file, the formatting looks great, but the structure is no longer recognized as json.
foo = {
"name" : "My great app",
"description" : "It's really cool.",
"version" : "0.0.1"
}
Does anyone know how to make clang-format format the bare object in the json file like in the second example?