Opengraph: Remove markdown from description, use first inserted image as og:image
Description
When using Opengraph either in Slack integration, facebook or twitter, few information is read from HTML elements we provide and control.
When an issue starts with or has markdown at the very beginning, there is a chance it will be part of the og:description
, making to a bad reading experience
Also it's common to start issue with a screenshot (more common when reporting a bug). Instead of rendering the screenshot in Opengraph we render something like ![filename](/uploads/ab8bd88c8d9e10293814023480808a0a09b8/huge_url_user_doesnt_care_about.png)
Proposal
- We should convert markdown to plaintext before slicing it to
og:description
- We should look for any image in issue/merge request description, and get the first one to be
og:image
as the content hero image.