W3C home > Mailing lists > Public > public-linked-json@w3.org > November 2014

"in #JSON-LD the keys in objects must be unique" -- why?

From: François-Paul Servant <francoispaulservant@gmail.com>
Date: Sat, 22 Nov 2014 14:55:53 +0100
Message-Id: <48995118-00FF-4B7F-92C7-41FBD437601E@gmail.com>
To: public-linked-json@w3.org
As I am a bit disappointed by the fact that keys in JSON-LD objects must be unique, I've tried to understand why it is so (as keys are properties, I didn't expect such a restriction - I know that we can use an array for multi-valued properties, but I would have expected that repeating a key would just have added more values - more triples to the graph). I've not been able to find an explanation (I tried searching this list without result, but I may have missed it). Could someone point me to some explanation / discussion on the topic? (it seems to me that I would be less disappointed if I understood why things are the way they are)

BTW, If you pass some JSON-LD that does not respect this rule to the playground (OK, not JSON-LD, then), you don't get any error or warning message (it seems that the latest value is used in the result)


Received on Saturday, 22 November 2014 13:56:21 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:18:42 UTC