To be precise, JSON was a replacement for XML, not the other way around. And the problem with XML was that it's way to verbose and difficult to write by hand, so it's exactly the opposite of the direction YAML/JSON5/... are taking.
The problem with XML was people were using it for every possible thing they could think of and 90% of those ideas were garbage.
The problem with XML was people were using it for every possible thing they could think of and 90% of those ideas were garbage.