From the course: JSON Essential Training

Unlock the full course today

Join today to access over 24,900 courses taught by industry experts.

Implement predefined key names

Implement predefined key names - JavaScript Tutorial

From the course: JSON Essential Training

Implement predefined key names

- [Instructor] Common vocabularies exist for many popular types of data, and JSON-LD supports tagging data using vocabularies from a variety of sources. To specify a vocabulary for a JSON object, you use the special @context key name. Each vocabulary has its own namespace identifier, which is a URI. This is a string that looks like a URL but may not correspond to an actual live resource on the web. However, the identifier is unique, and can be used programmatically to correlate multiple pieces of JSON-LD data that use a common vocabulary. The start files for this video contain a JSON object containing basic information about the h+ Sport company, and that's stored in the snippet.json file. I want to convert this to a JSON-LD snippet, using a public context. Schema.org defines contexts for a number of generic types of data. I noticed the thing section here includes an organization section. So I'll select that to…

Contents