No arrays are not allowed. Attributes can only be strings. But the children are kind of an array.
Previously SecretPancake on Feddit
No arrays are not allowed. Attributes can only be strings. But the children are kind of an array.
There is actually an extension to JSON: https://json5.org/
Unfortunately only very few tools support that.
Since XML can have attributes and children, it’s not as easy to convert to JSON.
Your JSON example is more akin to:
<address street_address="21 2nd Street" city="New York" ...></address>
JSON not supporting comments is a human rights violation
That’s so sassy I kinda respect it.
Too bad for those who fall for it.