Is context as an object an outdated format? #3073
Unanswered
spartahawk
asked this question in
Q&A
Replies: 1 comment
-
|
Not quite sure I understand your last question. An example would probably help. But to clarify what "context" is and the shapes it could have, take a look at the JSON-LD spec itself https://www.w3.org/TR/json-ld/#dfn-context |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I'm trying to make use of json-ld.net expansion and contraction given the json-ld formatting I'm seeing from major retailers. Are you aware of a discrepancy that follows?
In the repo readme, the example for expansion in the installation uses this example for the json-ld to be expanded:
{"@context":{ "test":"http://www.example.org/"},"test:hello":"world"}
However the major retailers I've looked at have it in something like the following format:
{"@context":"https://schema.org/", "@type":"Product", "image":"https://exampleimage.jpeg/",
"name":"fake product name", "sku":"2345624623", ...}
Is there a way to easily convert this latter format to the format where the context is containing individualized urls for each name/value pair?
Beta Was this translation helpful? Give feedback.
All reactions