Re: Relative URI Handling in JSON-LD

On 9/29/17 7:47 PM, Gregg Kellogg wrote:
> So, “@base”: “#” should be supported, and you’re likely seeing an untested corner-case in jsonld.js. Note, however, that expanded form is intended to make the terms in a document unambiguous:
>
>> Expansion has two important goals: removing any contextual information from the document, and ensuring all values are represented in a regular form. These goals are accomplished by expanding all properties to absolute IRIs and by expressing all values in arrays in expanded form. 
>> Note that in the output above all context definitions have been removed, all terms and compact IRIs have been expanded to absolute IRIs, and all JSON-LD values are expressed in arrays in expanded form.
> So, in your case “@base”: “#” should work, but “@vocab” will never be treated as document relative. This should be true for the TR as well as the CG Draft. I’m sure this was considered for the TR, but failed to pass muster. (see, for example #26 [3]).
>
> [1] https://json-ld.org/spec/latest/json-ld/#context-definitions
> [2] https://json-ld.org/spec/latest/json-ld-api/#expansion
> [3] https://github.com/json-ld/json-ld.org/issues/26
>

So do I conclude that "@base": "#" should work and issues I am having
are related to JSON-LD parser bugs?

-- 
Regards,

Kingsley Idehen       
Founder & CEO 
OpenLink Software   (Home Page: http://www.openlinksw.com)

Weblogs (Blogs):
Legacy Blog: http://www.openlinksw.com/blog/~kidehen/
Blogspot Blog: http://kidehen.blogspot.com
Medium Blog: https://medium.com/@kidehen

Profile Pages:
Pinterest: https://www.pinterest.com/kidehen/
Quora: https://www.quora.com/profile/Kingsley-Uyi-Idehen
Twitter: https://twitter.com/kidehen
Google+: https://plus.google.com/+KingsleyIdehen/about
LinkedIn: http://www.linkedin.com/in/kidehen

Web Identities (WebID):
Personal: http://kingsley.idehen.net/public_home/kidehen/profile.ttl#i
        : http://id.myopenlink.net/DAV/home/KingsleyUyiIdehen/Public/kingsley.ttl#this

Received on Tuesday, 10 October 2017 13:12:39 UTC