JSON-LD identation
authorYves Raimond <yves.raimond@bbc.co.uk>
Fri, 21 Feb 2014 10:00:38 +0000
changeset 1985 6491eba6852a
parent 1984 e9475f5a795b
child 1986 40676b1bbc16
JSON-LD identation
rdf-primer/index.html
--- a/rdf-primer/index.html	Fri Feb 21 10:54:45 2014 +0100
+++ b/rdf-primer/index.html	Fri Feb 21 10:00:38 2014 +0000
@@ -962,19 +962,19 @@
 <p>
 
       <pre class="example" title="JSON-LD">
-<span class="linenum">01</span>    {
-<span class="linenum">02</span>      "@context": "example-context.json",
-<span class="linenum">03</span>      "@id": "http://example.org/bob#me",
-<span class="linenum">04</span>      "@type": "Person",
-<span class="linenum">05</span>      "birthdate": "1990-07-04",
-<span class="linenum">06</span>      "knows": "http://example.org/alice#me",
-<span class="linenum">07</span>      "interest": {
-<span class="linenum">08</span>          "@id": "http://www.wikidata.org/entity/Q12418",
-<span class="linenum">09</span>          "title": "Mona Lisa",
-<span class="linenum">10</span>          "subject_of": "http://data.europeana.eu/item/04802/243FA8618938F4117025F17A8B813C5F9AA4D619",
-<span class="linenum">11</span>          "creator": "http://dbpedia.org/resource/Leonardo_da_Vinci"
-<span class="linenum">12</span>          }
-<span class="linenum">13</span>       }
+<span class="linenum">01</span>  {
+<span class="linenum">02</span>    "@context": "example-context.json",
+<span class="linenum">03</span>    "@id": "http://example.org/bob#me",
+<span class="linenum">04</span>    "@type": "Person",
+<span class="linenum">05</span>    "birthdate": "1990-07-04",
+<span class="linenum">06</span>    "knows": "http://example.org/alice#me",
+<span class="linenum">07</span>    "interest": {
+<span class="linenum">08</span>      "@id": "http://www.wikidata.org/entity/Q12418",
+<span class="linenum">09</span>      "title": "Mona Lisa",
+<span class="linenum">10</span>      "subject_of": "http://data.europeana.eu/item/04802/243FA8618938F4117025F17A8B813C5F9AA4D619",
+<span class="linenum">11</span>      "creator": "http://dbpedia.org/resource/Leonardo_da_Vinci"
+<span class="linenum">12</span>    }
+<span class="linenum">13</span>  }
       </pre>
 
       <p>The <code>@context</code> key on line 2
@@ -996,28 +996,28 @@
       </p>
 
 <pre class="example" title="JSON-LD context specification">
-<span class="linenum">01</span>    {
-<span class="linenum">02</span>      "@context": {
-<span class="linenum">03</span>         "foaf": "http://xmlns.com/foaf/0.1/", 
-<span class="linenum">04</span>         "Person": "foaf:Person",
-<span class="linenum">05</span>         "interest": "foaf:topic_interest",
-<span class="linenum">06</span>         "knows": {
-<span class="linenum">07</span>            "@id": "foaf:knows",
-<span class="linenum">08</span>            "@type": "@id"
-<span class="linenum">09</span>          },
-<span class="linenum">10</span>         "birthdate": {
-<span class="linenum">11</span>            "@id": "http://schema.org/birthDate",
-<span class="linenum">12</span>            "@type": "http://www.w3.org/2001/XMLSchema#date"
-<span class="linenum">13</span>         },
-<span class="linenum">14</span>         "dcterms": "http://purl.org/dc/terms/",
-<span class="linenum">15</span>         "title": "dcterms:title",
-<span class="linenum">16</span>         "creator": "dcterms:creator",
-<span class="linenum">17</span>            "subject_of": {
-<span class="linenum">18</span>            "@reverse": "dcterms:subject",
-<span class="linenum">19</span>            "@type": "@id"
-<span class="linenum">20</span>          }
-<span class="linenum">21</span>      }
-<span class="linenum">22</span>    }
+<span class="linenum">01</span>  {
+<span class="linenum">02</span>    "@context": {
+<span class="linenum">03</span>      "foaf": "http://xmlns.com/foaf/0.1/", 
+<span class="linenum">04</span>      "Person": "foaf:Person",
+<span class="linenum">05</span>      "interest": "foaf:topic_interest",
+<span class="linenum">06</span>      "knows": {
+<span class="linenum">07</span>        "@id": "foaf:knows",
+<span class="linenum">08</span>        "@type": "@id"
+<span class="linenum">09</span>      },
+<span class="linenum">10</span>      "birthdate": {
+<span class="linenum">11</span>        "@id": "http://schema.org/birthDate",
+<span class="linenum">12</span>        "@type": "http://www.w3.org/2001/XMLSchema#date"
+<span class="linenum">13</span>      },
+<span class="linenum">14</span>      "dcterms": "http://purl.org/dc/terms/",
+<span class="linenum">15</span>      "title": "dcterms:title",
+<span class="linenum">16</span>      "creator": "dcterms:creator",
+<span class="linenum">17</span>      "subject_of": {
+<span class="linenum">18</span>        "@reverse": "dcterms:subject",
+<span class="linenum">19</span>        "@type": "@id"
+<span class="linenum">20</span>      }
+<span class="linenum">21</span>    }
+<span class="linenum">22</span>  }
 </pre>
 
       For example, it will specify that the <code>birthdataorn</code> key