RE: Distinguishing a context document from an instance document

> Not at all, we still support external JSON-LD Context Documents. We
> just
> don't support external context documents inside of JSON-LD Context
> Documents to prevent recursion issues.

Oh OK.. now I got it.


> Just to clarify, this would be valid in a normal JSON-LD document, and
> would load bar.jsonld as well as creating the "foo" term mapping, but
> if the document were loaded because it was the target of a @context in
> a JSON-LD document, the processing rules would indicate that bar.jsonld
> not be loaded. In fact, this document should be considered to be
> invalid.

Hmm... I don't think that's a good idea. At least not if we don't have
different MIME types for contexts and instance documents. Since that depends
on how you invoke the API I would move that decision to the API. So, e.g.,
add a parameter like bool loadImportedContexts.

Do you really think we get into troubles if we load contexts inside
contexts? Was this ever a problem in CSS for instance? Of course an API has
to apply some reasonable limit but that's normal. We could also have a
best-practice in the spec. But I wouldn't like the idea of documents that
are valid JSON-LD documents, but invalid context documents if we don't
differentiate them accordingly.



--
Markus Lanthaler
@markuslanthaler

Received on Monday, 3 October 2011 06:17:28 UTC