Closed
Description
It would be helpful to be able to define separate default namespaces (@vocab) for the values based on the JSON-key. This would make it easier to hide URIs or namespaces from the data.
For example, when describing a Person, the JSON-LD could look like following pseudo JSON-LD (see "professionalTitle"):
{
"@context": {
"name": "http://xmlns.com/foaf/0.1/name",
"homepage": {
"@id": "http://xmlns.com/foaf/0.1/homepage",
"@type": "@id"
},
"professionalTitle": {
"@id":"http://example.org/title",
"@type":"@id",
"@vocab":"http://example.org/my-titles/"
}
},
"name": "Manu Sporny",
"homepage": "http://manu.sporny.org/",
"professionalTitle": "team-leader"
}
...instead of the current way where we need to define a namespace, such as "titles:team-leader" or using the full URI.