Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

5
  • 2
    Currently (July 2017), Google recommends unsing JSON-LD "wherever possible": developers.google.com/search/docs/guides/intro-structured-data Commented Jul 21, 2017 at 8:11
  • Do I understand right, JSON-LD can only let you specify general info about whole page, but you can't express which exactly parts of the webpage correspond to which object in JSON-LD? Like, if you have a list of books, you can specify in JSON-LD that this page shows a list of books, but you won't be able to tell which of the books described in the JSON-LD correspond to which exactly element on the webpage? If so, Microdata/RDFa have one more important advantage: providing context to screenreaders used by blind people, but maybe I'm missing something in how JSON+LD works. Commented Jun 15, 2023 at 4:55
  • 1
    @Klesun: Correct, with JSON-LD, there is no native way to connect the HTML elements with the JSON-LD statements. But even with Microdata and RDFa, the HTML is just the carrier. Microdata/RDFa parsers will just extract the statements, without any coupling to the HTML. I suppose it could be conceivable for user agents (like screen readers) to use Microdata/RDFa to get more context about the HTML, but AFAIK no one does that yet, and Microdata/RDFa were not designed for this to begin with. Commented Jun 16, 2023 at 12:14
  • in the case of JSON-LD, why not using anchors to connect HTML elements? Or is it too cumbersome? Commented Dec 15, 2023 at 11:44
  • @Ooker I had similar thoughts. You could adopt that convention. However, many people have not adopted the convention. A tool parsing the file would not know if such convention is followed. Sometimes it would be followed & sometimes not. I wonder what % of implementations fully or partially couple the DOM Element's id with the schema Element's id. Commented Mar 9, 2024 at 16:09