DEV Community

Anаѕ R.
Anаѕ R.

Posted on

Are We Going to See Metadata > Data Someday?!

My question her is: why Twitter and other social media use custom metadata, like Twitter card and Open Graph properties? I mean, aren't standard HTML metadata supposed to be enough?

Check this example:

<title>Lorem Ipsum</title>
<meta property="og:title" content="Lorem Ipsum" />

<meta name="description" content="Lorem ipsum dolor sit amet, consectetur adipiscing elit." />
<meta property="og:description" name="Lorem ipsum dolor sit amet, consectetur adipiscing elit." />

<link rel="canonical" href="https://domain.com/path/to/page/" />
<meta property="og:url" content="https://domain.com/path/to/page/" />

<meta name="twitter:card" content="summary" />

<meta property="og:image" content="path/to/logo.png" />
<link rel="icon" type="image/png" href="path/to/logo.png" sizes="128x128" />

Even with an ability to merge some lines:

<meta property="og:description" name="description" content="Lorem ipsum dolor sit amet, consectetur adipiscing elit." />

We still have redundancy.

Doesn't this phenomenon kind of reinventing-the-wheel?

According to this example, the only line that's not supported by W3C yet is twitter:card line, which could be simply renamed to sm:layout; something like this:

<meta name="sm:layout" content="summary" />

The rest of the values could be the same as Twitter's ones:

  • summary_with_image or visual_summary.
  • player.
  • app.

For visual_summary case, we could write:

<meta name="sm:layout" content="summary" />
<link rel="cover_image" type="image/png" href="https://domain.com/path/to/cover.png" sizes="640x400" />

Even Open Graph protocol, which came to standard this issue, doesn't rely on the already existing metadata!

What do you think?

Top comments (1)

Collapse
 
dbredvick profile image
drew.tech

Twitter annoys me with how custom they went for their meta implementation.

I struggle twice as much getting their share cards to work as compared to Facebook, LinkedIn, etc.

Take a look at Facebook & LinkedIn’s implementations. They follow OG standards much better. That might give you some inner peace 🙂