Skip to content

Microdata and RDFa in AMP #4919

@jaygray0919

Description

@jaygray0919

Microdata is supported in AMP but RDFa is not.
Here is the source of the mark-up below: [http://schema.org/CreativeWork]

Microdata:

<div itemscope itemtype="http://schema.org/CreativeWork">
<span itemprop="name">Resistance 3: Fall of Man</span>by 
<span itemprop="author">Sony</span>,Platform: Playstation 3 Rated:
<span itemprop="contentRating">Mature</span>
</div>

RDFa:

<div vocab="http://schema.org/" typeof="CreativeWork">
<span property="name">Resistance 3: Fall of Man</span> by 
<span property="author">Sony</span>, Platform: Playstation 3 Rated:
<span property="contentRating">Mature</span>
</div>

AMP validator throws the following errors on RDFa mark-up:

The attribute 'vocab' may not appear in tag 'div'.
The attribute 'property' may not appear in tag 'span'.

There are other RDFa object properties, such as about, rel and compact URIs (CURIE), that also are rejected. A CURIE is in the form xmlns:owl.

When <amp-img> is used in place of <img>, AMP validator rejects 'property' in both Microdata and RDFa mark-up.

Will the Google AMP team consider supporting RDFa mark-up in AMP documents?
Will you support Microdata and RDFa mark-up for AMP-specific elements such as <amp-img>

/jay gray

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions