MediaWiki

Difference between revisions of "SandboxData.js"

m
m
Line 8: Line 8:
 
}  
 
}  
 
************** */
 
************** */
var data = [{"item":{"type":"uri","value":"https://lingualibre.org/entity/Q12"},"itemLabel":{"xml:lang":"en","type":"literal","value":"beginner"}},{"item":{"type":"uri","value":"https://lingualibre.org/entity/Q13"},"itemLabel":{"xml:lang":"en","type":"literal","value":"average level"}},{"item":{"type":"uri","value":"https://lingualibre.org/entity/Q14"},"itemLabel":{"xml:lang":"en","type":"literal","value":"good level"}},{"item":{"type":"uri","value":"https://lingualibre.org/entity/Q15"},"itemLabel":{"xml:lang":"en","type":"literal","value":"native"}}];
+
var data = [
 +
  {
 +
    "item": {
 +
      "type": "uri",
 +
      "value": "https://lingualibre.org/entity/Q12"
 +
    },
 +
    "itemLabel": {
 +
      "xml:lang": "en",
 +
      "type": "literal",
 +
      "value": "beginner"
 +
    }
 +
  },
 +
  {
 +
    "item": {
 +
      "type": "uri",
 +
      "value": "https://lingualibre.org/entity/Q13"
 +
    },
 +
    "itemLabel": {
 +
      "xml:lang": "en",
 +
      "type": "literal",
 +
      "value": "average level"
 +
    }
 +
  },
 +
  {
 +
    "item": {
 +
      "type": "uri",
 +
      "value": "https://lingualibre.org/entity/Q14"
 +
    },
 +
    "itemLabel": {
 +
      "xml:lang": "en",
 +
      "type": "literal",
 +
      "value": "good level"
 +
    }
 +
  },
 +
  {
 +
    "item": {
 +
      "type": "uri",
 +
      "value": "https://lingualibre.org/entity/Q15"
 +
    },
 +
    "itemLabel": {
 +
      "xml:lang": "en",
 +
      "type": "literal",
 +
      "value": "native"
 +
    }
 +
  }
 +
];

Revision as of 19:48, 19 January 2022

/* **************
SELECT ?item ?itemLabel WHERE {
SERVICE wikibase:label {
  bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" .
} 
?item prop:P2 entity:Q5
} 
************** */
var data = [
  {
    "item": {
      "type": "uri",
      "value": "https://lingualibre.org/entity/Q12"
    },
    "itemLabel": {
      "xml:lang": "en",
      "type": "literal",
      "value": "beginner"
    }
  },
  {
    "item": {
      "type": "uri",
      "value": "https://lingualibre.org/entity/Q13"
    },
    "itemLabel": {
      "xml:lang": "en",
      "type": "literal",
      "value": "average level"
    }
  },
  {
    "item": {
      "type": "uri",
      "value": "https://lingualibre.org/entity/Q14"
    },
    "itemLabel": {
      "xml:lang": "en",
      "type": "literal",
      "value": "good level"
    }
  },
  {
    "item": {
      "type": "uri",
      "value": "https://lingualibre.org/entity/Q15"
    },
    "itemLabel": {
      "xml:lang": "en",
      "type": "literal",
      "value": "native"
    }
  }
];