#microformats 2018-11-04

2018-11-04 UTC
[eddie], [kevinmarks] and [tantek] joined the channel
#
aaronpk
hmm noticing an inconsistency with mf2 prefixes and the value-class pattern
#
aaronpk
since it requires class="value"
#
aaronpk
which is not prefixed
#
Zegnat
Yep. I am not sure anything about vcp has been upgraded during the mf2 rewrite
#
aaronpk
it did
#
aaronpk
that's mf2 with the value class pattern
#
sknebel
yeah, but it doesn't necessarily has *changed* much from how it worked during mf1
#
sknebel
although I guess a few details have there been, since some mf1 concepts don't exist in mf2
#
aaronpk
i'm inclined to not translate this to the property attribute
#
aaronpk
it just seems weird that there is some mf2 stuff that isn't prefixed
[kevinmarks] joined the channel
#
[kevinmarks]
Property?
#
aaronpk
from a discussion session at indiewebcamp berlin
#
Loqi
[aaronpk] #204 parse microformats classes from the property attribute
[jgmac1106] joined the channel
#
[kevinmarks]
That seems like a breaking change if people publish that way. Did you find new evidence that u- classes were causing actual problems?
#
aaronpk
yes that was the whole discussion yesterday
#
aaronpk
there are notes
#
[kevinmarks]
I saw the sonniesedge.co.uk post, but not the notes
#
aaronpk
hm not as thorough as I had hoped
#
aaronpk
I will go expand
[tantek] joined the channel
#
Loqi
When u- means style= 2016-05-24
#
aaronpk
different argument
#
aaronpk
okay added a bit
#
aaronpk
the main new point that was made is when a new developer is looking at the HTML source, there is no indication that a class is actually a microformats class as opposed to being used for styling, unless that person is already familiar with microformats
#
[kevinmarks]
Ah, yeah. That is a problem. Though if you are using BEM or something it should be obviously different. The real answer is to add integration tests that parse the microformats, like mastodon did.
#
aaronpk
that's also a different problem
#
aaronpk
but addresses the second point I added to the notes
#
[kevinmarks]
Or if you are using a preprocessor build model, compile the property into classes. When you run the rest of the build pipeline
[pfefferle], [dominik], [tantek], [jgmac1106], [kevinmarks], [eddie], [grantcodes], [frank], jgmac1106, [cleverdevil], jmac, [sebsel], TheTemp, [Khurt] and [dave] joined the channel
#
[dave]
Sorry to disrupt, but if anyone is interested, that Chrome extension I worked on has merged in my updates: https://beatonma.org/app/microformats-reader
#
Loqi
Michael Beaton
#
gRegorLove
Interesting discussion on property vs class
#
gRegorLove
The HTML 5.2 section linked there seems to be about the ARIA properties, though, which are prefixed with "aria-" e.g. `aria-labeledBy="id"`
#
gRegorLove
Added to notes
#
gRegorLove
I have mixed feelings about it. We've referred to mf2 as implementing lessons from RDFa and superseding it. http://microformats.org/wiki/rdfa
#
KartikPrabhu
not sure why class is a problem
#
KartikPrabhu
the "style" vs other stuff already exists in the class attribute anyway
#
KartikPrabhu
microformats fit nicely into "encouraged to use values that describe the nature of the content, rather than values that describe the desired presentation of the content."
#
gRegorLove
Re-using RDFa properties seems to muddy whether it's an mf2 document or an RDFa document. At a certain point, what's our answer to "why not just use RDFa?"
#
Zegnat
The parsing issue should be updated with the actual arguments, probably. So a clearer discussion can be had with the people who weren't in the room.
#
Zegnat
I'll clear some room in my calendar for that tomorrow on my way home.
#
gRegorLove
Yeah, I'd like some clarity on what the proposed authoring change is too. Is it "use property first, or class as a fallback" or something different.
#
KartikPrabhu
before the authoring change, is there any reason to not use class
#
gRegorLove
Summary of the discussion is the two reasons are: clashing with CSS naming conventions and devs removing HTML class names because they appear to be unused.
#
KartikPrabhu
those are not mf2 specific anyway
#
gRegorLove
But agreed, I'm not certain those are strong enough reasons. Look forward to reading more reasoning on it.
#
KartikPrabhu
devs could remove properties too
[stefp] and [jgmac1106] joined the channel
#
aaronpk
The argument is specifically that class is primarily used and understood as styling, so someone who sees a class name they aren't styling may remove it. In contrast, someone who sees a "property" attribute and doesn't know what it's for may actually think twice before removing it because it was clearly there for some reason rather than just being an unused styling class
#
KartikPrabhu
that is the complete opposite of what the HTML spec says for class attribute
#
aaronpk
Doesn't matter what specs say ultimately
#
KartikPrabhu
you can use any attribute for styling
#
aaronpk
vs how things happen in practice
[schmarty] joined the channel
#
KartikPrabhu
well then, the "best" way to be fool-proof is to invent a new attribute like microformats = "h-entry"
#
KartikPrabhu
and there we have it. we are into RDF land
#
aaronpk
That was a proposal but would cause html to not pass most validation tools due to the unrecognized property
#
KartikPrabhu
if specs are not very relevant then neither are validators
#
KartikPrabhu
in practice, you can put any attribute on any HTML tag
#
aaronpk
But people do actually run their code through validators and try to fix it when it fails
#
aaronpk
I'm just recapping the discussion from the session. Apparently the notes weren't good enough
#
gRegorLove
That's what I gathered from the notes. Currently I lean towards educating about the use of `class` vs introducing `property` in the mix.
#
gRegorLove
Unless it's really becoming a big problem. Maybe it is.
#
aaronpk
Charlie was very clear on that point regarding her development teams
#
gRegorLove
Is it just the u- prefix or others?
#
aaronpk
Everything
#
aaronpk
its just that u- is the oldest example of a conflicting prefix
#
aaronpk
Seb brought up that p-px is being used now too
#
aaronpk
but conflicting properties is less the issue here
#
gRegorLove
bootstrap4 has some too, iirc
#
aaronpk
Or rather the fact that random classes might end up in the parsed result is not the issue
#
aaronpk
think about the conflict from the other perspective
[calumryan] joined the channel
#
aaronpk
youre used to bootstrap4 which uses u- and p- prefixed class names, and you start seeing these other similar looking classes but they are not documented in bootstrap or being used for styling
#
KartikPrabhu
not sure why these are conflicts. a mf2 parser can just parse p-px
#
KartikPrabhu
mf2 consumers won't be using it
#
aaronpk
Again, that's not the point
#
gRegorLove
Ok, but which is a better solution? Direct devs not to remove things they don't understand, or change how to publish mf2? I'm not sure.
#
gRegorLove
The latter feels like a big hammer
#
aaronpk
The former feels like an impossible task because it requires changing the bahavior of even more people than who are using mf2
#
gRegorLove
Isn't that up to a project team that decides to use mf2 to communicate?
#
aaronpk
No, because there may be people in the code base who have no vested interest in the mf2
#
KartikPrabhu
so this will be mf3 ?
#
gRegorLove
It just sounds hypothetical to me. If using mf2 is important they should communicate that to people touching the code.
#
aaronpk
I wish the session had been recorded because Charlie was very clear on her reasons for being unable to use mf2 with her team right now
#
gRegorLove
"should" is hypothetical too, I realize, heh
[jgmac1106] joined the channel
#
[jgmac1106]
[aaronpk] wonder if she would do a microcast with/without you or post on it.
#
aaronpk
good idea
#
[jgmac1106]
Probably would solve 90% of WordPress problems... A totally arbitrary number based on an over estimation of my knowledge
#
[jgmac1106]
Also I can't remember. Did I get the link to the NYC building block session to you?
#
aaronpk
not yet
#
Zegnat
I think Charlie’s point was mostly: here we have a somewhat bigger scale institute than just private sites, and people with an interest in marking things up semantically. But the people with that interest are not the developer team, or possible outside front-end workers. At which point you have very few choices: educate the entire staff, or not do it at all.
#
Zegnat
So she came into the session basically asking what she could use that wasn’t microformats, as the signal was clear that adding microformats the way currently specified was just never going to happen. So Microdata, RDFa, and JSON-LD, all came to mind, but we also wanted to look into alternative ways to express the mf2. (One thing also mentioned: the idea to give WP pages separate URLs that already provide mf2-json.)
#
Zegnat
This led to the question, what if we just do not use the class attribute? What other attributes are there? We did a lot of checking in the spec and there is no clear custom-attribute way supported by HTML5 (other than data-* prefixed ones, who have a different defined purpose). Then someone (I think tantek) mentioned that OpenGraph is using a `property` attribute. And at the time in the room nobody really seemed to have a reason why
#
Zegnat
we couldn’t also do that. (Apart from stepping into RDFa territory, and that probably needs a little more research too.)
#
Zegnat
That was my take-away from the session, at least. Not trying to speak for anyone else :)
[kevinmarks] joined the channel
#
Zegnat
Oh, copyability was also mentioned. Does the HTML make more sense just in snippets if it doesn’t get mixed in with classes. But I don’t remember the exact arguments there.
#
Zegnat
Going to finish up packing now, so I’ll get some of this documented in the parsing issue tomorrow.
#
sknebel
Because I'm thinking of it right now, two random points: there's of course also the option of using mf as a hidden islands. And the fact that e.g. for bridgy mf2 formated HTML feeds already are supported, even if they're behind a feed link, while the json feeds aren't
#
gregorlove
edited /history-of-microformats (+139) "/* 2010 */ +microformats2 proposed and conceptually explored during a discussion session at FOO East 2010."
(view diff)
#
gregorlove
edited /history-of-microformats (+12) "/* 2010 */ date"
(view diff)
#
[kevinmarks]
I would like to have heard Charlie talk about that, and what the tool chain was that makes this likely. The reason we ended up with prefixes initially was to avoid the arbitrary class problem.
mblaney joined the channel