I think XHTML is largely a distraction here since the 2000s. HTML5 standardized parsing and the mechanisms for including non-display data.
Since the decline of IE8 or so, almost all of the work I’ve had working with data in HTML has been due to differences in the data models, which is also a problem using JSON or XML.