VIE icon indicating copy to clipboard operation
VIE copied to clipboard

URIs don't begin with < or end with >

Open jpmccu opened this issue 12 years ago • 4 comments

Especially ones embedded in RDFa. You're probably thinking of N3-based representations, but the <>s aren't actually part of the URI. I may have missed some edge cases where you were relying on the <>s for something, but at least now your URIs aren't broken, and you can accept real ones.

jpmccu avatar Jul 06 '12 04:07 jpmccu

This pull request fails (merged 7502d468 into 0289577c).

travisbot avatar Jul 06 '12 04:07 travisbot

Thanks for the contribution! URIs were wrapped in < and > in older JSON-LD specifications, which is why we still do it.

There has been some discussion (and a ticket, #110) on this, and the most important consideration is how to do this in a way that it doesn't break existing implementations. For this we need especially isReference to be rock-solid. And probably we need a version of toJSONLD that is able to return the old format.

bergie avatar Jul 06 '12 08:07 bergie

That's reasonable. I think that the library should focus on keeping the <>s in JSON-LD without pulling them into the library itself. I'll look again at toJSONLD and isReference and the test failures. I was trying to read in some RDFa from an HTML page which failed originally because I didn't include <>s around my URIs, as the RDFa specification says. I couldn't find a way to execute the unit tests from my local git repo. Is there documentation on that?

Thanks, Jim

jpmccu avatar Jul 06 '12 11:07 jpmccu

@jimmccusker you need to build your local VIE version by running ant.

Then just open test/index.html file in a browser.

Optionally you can also do:

$ npm install
$ npm test

bergie avatar Jul 06 '12 11:07 bergie