Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

JSON for Linked Data's documentation and playground site

License

NotificationsYou must be signed in to change notification settings

json-ld/json-ld.org

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

Join the chat at https://gitter.im/json-ld/json-ld.org

This is the source for thehttps://json-ld.org/ website.

JSON-LD (JavaScript Object Notation for Linking Data) is a lightweight LinkedData format. It is easy for humans to read and write. It is easy for machinesto parse and generate. It is based on the already successful JSON format andprovides a way to help JSON data interoperate at Web-scale. If you are alreadyfamiliar with JSON, writing JSON-LD is very easy. There is a smooth migrationpath from the JSON you use today, to the JSON-LD you will use in the future.These properties make JSON-LD an ideal Linked Data interchange language forJavaScript environments, Web services, and unstructured databases such asCouchDB and MongoDB.

If you are already using JSON-LD, add yourself to thelist of users in our wiki.

A Simple Example

A simple example of a JSON object with added semantics::

{"@context":"https://json-ld.org/contexts/person.jsonld","@id":"http://dbpedia.org/resource/John_Lennon","name":"John Lennon","born":"1940-10-09","spouse":"http://dbpedia.org/resource/Cynthia_Lennon"}

The example above describes a person whose name is John Lennon. The differencebetween regular JSON and JSON-LD is that the JSON-LD object above uniquelyidentifies itself on the Web and can be used, without introducing ambiguity,across every Web site, Web services and databases in operation today.

The Playground

If you would like to play around with JSON-LD markup, you may do so here:

https://json-ld.org/playground/

The Specifications

If you are a developer, you may be interested in the official JSON-LD W3Cspecifications:

A list of all previous specification drafts is also available.

https://json-ld.org/spec/

Website Development

To develop this website locally:

# install dependenciesnpm i# to just build the static files to `_site/`npm run build# to rebuild the files on changesnpm run watch# to serve `_site/` with Cloudflare Pages feature supportnpm run pages# visit http://localhost:8788/

Additionally, if you want to use or test the playgroundhttp: proxy, also runtheWrangler server to emulate theCloudflare Pages Functions code:

npm run dev

Editor Development

The new Playground is build usingCodeMirror 6 and is integrated into thesurrounding UI usingpetite-vue.

  • playground/next/index.html has the HTML and petite-vue markup-level code
  • playground/next/editor.mjs contains the JS for setting up CodeMirror andattaching it to the DOM via petite-vue

Thenpm run build:editor command usesRollup to build the final JS bundleatplayground/next/editor.bundle.js which contains the browser ready JS code.

Only the first two should be edited. However,editor.bundle.js should be builtlocally and committed along with the rest of the site to avoid unnecessary buildtime/cost/waste at deployment time.

Website Analytics

Google Analytics has been used on this site since 2013. There are two GAidentifiers in use:

  • UA-40462488-1 forprimer/,spec/, andrequirements/
  • UA-42886053-1 for everything else (per the default)

The default code can be overridden by settingga to a specific number (ex:40462488) in the page's front matter.

About

JSON for Linked Data's documentation and playground site

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Contributors62


[8]ページ先頭

©2009-2025 Movatter.jp