Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Case: JSON-LD + Microdata #5

Closed
AutoSponge opened this issue Mar 20, 2019 · 0 comments · Fixed by #33
Closed

Use Case: JSON-LD + Microdata #5

AutoSponge opened this issue Mar 20, 2019 · 0 comments · Fixed by #33

Comments

@AutoSponge
Copy link
Contributor

AutoSponge commented Mar 20, 2019

Case

JSON-LD provides an established standard for embedding data in HTML. Unlike other microdata approaches, JSON-LD helps to reuse standardized annotations through external references.

Issues:

  • additional data invisible to text to speech
  • additional data invisible to screen readers
  • not an established "type"/published schema

Example from https://quiet-collar.glitch.me/,JSON-LD + Microdata:

<script type="application/ld+json">
  // @id is an md5 hash of the original (normalized) ssml
  // easy to cache, generate, differentiate, and predict
  // can be fully externalized
  {
    "@id": "http://example.org/Pronunciation/en_us/36ce11650d7baceb0e1877515ff33aba",
    "@context": "http://schema.org/",
    "type": "Pronunciation",
    "alphabet": "ipa",
    "phoneme ": "pecan",
    "ph": "pɪˈkɑːn"
  }
</script>
<script type="application/ld+json">
  {
    "@id": "http://example.org/Pronunciation/en_us/814f8be5715b0e423242430ee2b2b6ef",
    "@context": "http://schema.org/",
    "type": "Pronunciation",
    "alphabet": "ipa",
    "phoneme ": "pecan",
    "ph": "ˈpi.kæn"
  }
</script>
<p>
  You say, <span itemscope="" itemtype="http://example.org/Pronunciation">
    <link itemprop="url" href="hhttp://example.org/Pronunciation/en_us/36ce11650d7baceb0e1877515ff33aba">pecan</span>. 
  I say, <span itemscope="" itemtype="http://example.org/Pronunciation">
    <link itemprop="url" href="http://example.org/Pronunciation/en_us/814f8be5715b0e423242430ee2b2b6ef">pecan</span>.
</p>
@AutoSponge AutoSponge changed the title Implementation: JSON-LD + Microdata Use Case: JSON-LD + Microdata Apr 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant