#3020 ✓closed
Stefan Doehla

Markdown heading levels not working

Reported by Stefan Doehla | March 3rd, 2022 @ 12:58 PM

My previously filed ticket seems to be not saved, thus just as a backup here agin (please mark as duplicate if I missed something).

The following Markdown

H1
=

H2
==

H3
===

H4
====

yields this result:

<!DOCTYPE html>
<html>
<head>
<style>body > img, blockquote >img { max-width: 100%; }
body { font-family: "Menlo"; font-size: 8.2pt; }
</style>
<meta http-equiv="x-dns-prefetch-control" content="off">
<meta http-equiv="Content-Type" content="text/xhtml; charset=utf-8">
<style>
div.markdown { white-space: normal; }
body { font-family: sans-serif; }
h1 { font-size: 1.4em; }
h2 { font-size: 1.2em; }
h3 { font-size: 1.1em; }

...
</style>
</head>
<body caret_uuid="D348A516-0ABC-4674-AFED-2A7B64EBB756"><div class="markdown">
<h1 data-sourcepos="1:1-3:0">H1</h1>
<h1 data-sourcepos="4:1-6:0">H2</h1>
<h1 data-sourcepos="7:1-9:0">H3</h1>
<span D348A516-0ABC-4674-AFED-2A7B64EBB756="0.500000" style="display:inline "></span><h1 data-sourcepos="10:1-11:4">H4</h1>

</div></body>

</html>

Note that the header levels are not correctly converted to HTML header levels. Also h4-h6 are not converted properly (but I guess they're part of both Markdown and HTML).

Comments and changes to this ticket

  • benny

    benny March 3rd, 2022 @ 01:23 PM

    • State changed from “new” to “closed”

    I believe the result is as expected. See documentation here.

    You can do this:

    # H1
    ## H2
    ### H3
    #### H4
    

    and more limited:

    H1
    ==
    
    H2
    --
    
  • Stefan Doehla

    Stefan Doehla March 4th, 2022 @ 12:30 PM

    Ah, I was living under a false assumption for such a long time, having used nested bulleted lists now for years. Thanks for hinting me and sorry for the extra work.

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Mac OS X email client.

Shared Ticket Bins

People watching this ticket

Pages