material-ui
material-ui copied to clipboard
[docs] Add open-graph prefix
Trying to fix why doc preview has bad preview image on LinkedIn.
Seems to be a common StackOverflow question that can be solved by defining of prefix in the header
To do: test the preview with LinkedIn inspector to see if fix is working
Messages | |
---|---|
:book: | Netlify deploy preview: https://deploy-preview-34382--material-ui.netlify.app/ |
Generated by :no_entry_sign: dangerJS against 59beaa3eb370f823291909a8edadd16e8e6dfc08
Seems to work. I also included extra information: the authors and the publication date, such that algorithm could detect that it's fresh content
https://www.linkedin.com/post-inspector/inspect/https:%2F%2Fdeploy-preview-34382--material-ui.netlify.app%2Fblog%2Fintroducing-mui-base%2F
Interesting, it seems to be a continuation of #33954.
Regarding testing the changes, when I compare deploy-preview-34382--material-ui.netlify.app/blog/introducing-mui-base with mui.com/blog/introducing-mui-base, I can only see one difference:
![]()
So I conclude that only
<meta name="author" content="
makes a difference, the rest has no impacts grin
Effectively, I don't know why I got the wrong image the first time 🤔
the prefix might not be a bad thing. If the date with the full date/time is recognized by LinkedIn it will be an improvement
There seems to be a problem with the publication date still. Do you intend to fix it in this PR or is it solely about the preview image?
@michaldudak Thanks for the reminder :)
I tend to think that the LinkedIn parser is ~~broken~~ strange
I had a look at two articles:
- https://retool.com/blog/new-free-plan-2022/ : inspector says no author, no date
- https://retool.com/blog/git-branching-with-source-control/ : inspector says no author, date found
I inspeceted the meta tag, those with or are the same, so no reason one has it's date detected, and the other not
I added the prefix for article tags: article: http://ogp.me/ns/article#"
but does not seems to change the behavior
Yeah, that's strange indeed. Let's merge what we have. It's an improvement anyway.
I have rebased and pushed a few more improvements.
@alexfauquette can we merge this so that we can include in the today's release?