Skip to content

Markdownify post title and strip markdown from other areas #96

@runofthemillgeek

Description

@runofthemillgeek

Suggestion/Enhancement

Currently, post titles are rendered as is even if they are formatted as markdown. For example, this post has the raw title text as:

CSS `stretch` sizing keyword

But typo right now when built renders it as follows:

Image

The same goes for post listing pages:

Image

The <title> tag and og:title are also rendered the same way, which is probably not desirable as link previews will now contain all the markdown syntax.

Proposal

This feels a bit janky to me and it might be desirable to parse these as markdown itself but in different ways depending on context:

  1. For main post title: markdownify title and render it.
  2. For breadcrumbs: markdownify and plainify to convert into plain text.
  3. For <title> and og:title: markdownify and plainify to convert into plain text.
  4. For post listings, markdownify post titles and render them.
  5. Perhaps a site-wide config or page-level config to turn this on/off is doable

There might be other areas I missed but wanted to get feedback first.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions