-
Notifications
You must be signed in to change notification settings - Fork 19
Consider acknowledging the @content attribute #20
Comments
This would be as a synonym for |
Looking at that, about 60% are of the examples are valid given that they use If the processors actually handle the
Do you have some test results? |
Here's a test
Looking around https://w3c.github.io/html/fullindex.html#attributes-table there are several elements listed in that table for 'value' but not enough to match @content's functionality yet as I understand it. /cc @gkellogg |
According to the Microdata to RDF spec, See microdata-rdf/issues#7. If you update this in Microdata, we'd also need to update Microdata to RDF (or simply include the RDF conversion bits in the new Microdata spec). |
The Yandex Structured Data Validator recognised it too. @gkellogg yes, this would be a substantive change. On the other hand, if that's what happens in reality, it seems to be a reasonable one to make. @danbri do you have any handy data on the use of |
Here's a test where the answers are clearer - if
|
Not handy but I could look into it. I guess the central interest is on non-meta elements, maybe ratios would be something I could get shared. |
Note that the Content model for span does not include If you want to make IIRC, we were leveraging off of the HTML content model to use Arguably, having |
Yep. And since we are already changing / extending HTML in this spec, I suggest that if we decide we want to do this, we start by stating that for microdata |
@gkellogg if we made @content global, would you be likely to update any implementations to track this? My understanding is that at least major implementations (Google, Yandex) already treat it as global, and that it addresses practical shortfalls of Microdata. So I'd like to propose we make @content a global HTML attribute. |
@danbri, I'd certainly update my implementation. Do you imagine incorporating Microdata to RDF in your Microdata update? If not, we'll need to plan on updating that too. |
Note that there are other attributes with special content-like attributes:
Of these, it might be worth considering |
Linter and Distiller updated to allow |
That seems like we probably should just do this… We've got enough interop to show it can be done easily, we have schema.org examples out there suggesting it and we know that people use that, we have an example that it probably isn't a major imposition on implementations, and in any event RDFa already parses this so it brings us into closer alignment. I'd like to have the data on usage in the wild, but if #35 lands, I'll happily put this in the spec… (I don't think this conflicts with #35 but they both touch a bunch of places, and I am sure that after landing the two there will be cleanup to do, plus #35 would benefit from a few pairs of thoughtful eyes so a couple of days extra seems wearable). Assigning it to me with the assumption that we will move forward... |
+1, adding @content globally sounds fine to me. I'd check with @Hixie to understand why it wasn't included in the first iteration of Microdata (other than it being "allowed" in the content model - what are the validators going to say? Do people care about validating HTML these days? I know we stopped doing this a long time ago at our company). |
It fared poorly in usability studies. |
@gkellogg on #20 (comment) : I think I would prefer to issue a new release of the RDF conversion document rather than adding it to the core microdata spec. It would create too much (unnecessary) discussion about the role of RDF, and we do not need that. I am a bit neutral whether the RDF conversion spec should remain a note or become a rec. But I have a mild preference of republishing it in the Web Platform WG. |
+1 adding I am not sure when I would update the Microdata parsers in RDFLib and in my Microdata distiller, but I would certainly try to find time for it (however, the prerequisite is to update the RDF conversion document as well. |
Can we keep the "RDF conversion" question in #3, so this issue is just about whether or not to add |
@chaals, apologies:-) |
@Hixie said:
So my +1 to add it is now a +0. Do we either have 1) Data from @Hixie noting the usability studies (doubtful, as Google has not released this data to the public AFAIK), or 2) Demonstration that "@content" is being used across X million sites in Microdata markup. If we don't have data for either, we're just flying by the seat of our pants (which is usually a bad thing to do spec-wise). There is another option here, which is to fix the schema.org examples. |
I've never understood how you can do usability studies on the use of attributes. RDFa allows the use of |
An @content attribute is used elsewhere in the HTML universe (at least RDFa).
It appears that at schema.org we have mistakenly assumed it was part of Microdata or HTML proper. If you grep for @content appearing alongside @itemprop in the schema.org examples, there are lots of examples which use it. This idiom is intended to allow a more machine-friendly property value be parsed out, while something more appropriate to human audiences is also accessible for non-machines. It may also help with l18n where schema designs contain e.g. English-language strings but the markup is otherwise in another natural language.
The text was updated successfully, but these errors were encountered: