We encounter an issue when email contain hyphens underlining a line, which markdown recognises as a heading. This is trimmed away by the trim algo. We have to always show the trimmed content since many people use our instance by email only.
Steps to reproduce:
Basically in the Advanced Email test enter:
This is text before
Header
------
This is text after
Which in markdown would be rendered as:
This is text before
Header
This is text after
The result is that the text before the header is removed and after is elided!
Is there a way to adjust the trimming to not elide lines of hyphens that follows a line with the same number of characters? At least markdown seems to be able to deal with that.
Yes of course disabling the trimming does not elide the next
However, the problem then comes when people reply to a very very long email thread via email and then all that thread is shown the web view. That is not nice. Hence I would like to re-enable the trimming!
So you want the trim feature enable but the ----- signature removal feature? Thatās tricky. Can users be told to use ATX headings instead of Setext headings?
As the lead developer of the application that creates the emails @artur talks about: Yes, we could change it (or use ^^^^ instead of ---- in the āunderlineā), but this is technically not markdown but simply a text/plain email thatās formatted in a āniceā way for humans. And the āunderlinedā headings do look a bit nicer IMHO than using markdown-style # something headings
Anyway, donāt email signatures that are delimited with -- usually have a blank line right before the -- line? So maybe that could be taken into account when parsing emails?