- From: simon via GitHub <sysbot+gh@w3.org>
- Date: Fri, 21 Apr 2017 08:09:18 +0000
- To: public-poe-archives@w3.org
After skimming through JSON-LD's [5.1 The Context](https://www.w3.org/TR/json-ld/#the-context) section I'm wondering whether we are actually using `"@context"` correctly. (I'm not a JSON-LD expert though)
According to [5.1 The Context](https://www.w3.org/TR/json-ld/#the-context) Example 5:
```json
{
"@context":
{
"name": "http://schema.org/name",
"image": {
"@id": "http://schema.org/image",
"@type": "@id"
},
"homepage": {
"@id": "http://schema.org/url",
"@type": "@id"
}
},
"name": "Manu Sporny",
"homepage": "http://manu.sporny.org/",
"image": "http://manu.sporny.org/images/manu.png"
}
```
A policy like:
```json
{
"@context": {
"odrl": "http://www.w3.org/ns/odrl/2/"
},
"@type": "odrl:Offer",
"@id": "http://example.com/policy:1012",
"permission": [{
"target": "http://example.com/music:1012",
"action": "odrl:play"
}]
}
```
should actually look like:
```json
{
"@context": {
"odrl": "http://www.w3.org/ns/odrl/2/",
"permission": "http://www.w3.org/ns/odrl/2/permission",
"target": "http://www.w3.org/ns/odrl/2/target",
"action": "http://www.w3.org/ns/odrl/2/action",
"play": "http://www.w3.org/ns/odrl/2/play"
},
"@type": "odrl:Offer",
"@id": "http://example.com/policy:1012",
"permission": [{
"target": "http://example.com/music:1012",
"action": "play"
}]
}
```
right?
--
GitHub Notification of comment by simonstey
Please view or discuss this issue at https://github.com/w3c/poe/issues/137#issuecomment-296119648 using your GitHub account
Received on Friday, 21 April 2017 08:09:25 UTC