10

I just noticed this answer that got bumped up recently on RPG SE. The editor was trying to replace a formerly MathJax-based table with one in Markdown, which is fine. But the table isn't working at all.

So, I hit Edit, and the live preview has the table just fine. Clearly, the server-side Markdown renderer and the client-side one for live preview, aren't matching up here.

For reference, here's the same exact table:

...blahblah |Magic Item Ingredients || |---|---| |Item Rarity | CR Range | |Common | 1—3 | |Uncommon | 4—8 | |Rare | 9—12 | |Very rare | 13—18 | |Legendary | 19+ |

I can confirm that the table above looks perfectly fine in the preview prior to submitting this report.

And after posting, it worked fine, until I added actual text in the blockquote, before the table, so that apparently has something to do with it.

Even if this broken table is okay, the two different renderers should probably be built to agree on the results, so people don't post things that look good in the preview, but are broken when actually displayed.

12
  • 7
    The parser is very picky about whitespace. Adding an extra blank line solves all ambiguity.
    – rene
    Jan 26, 2021 at 13:06
  • 6
    That's all well and good, but the two parsers should be picky in the same way, so people don't post things that then mis-render. Jan 26, 2021 at 13:20
  • 1
    Yeah, I was looking for an existing bug report on that as I'm sure I've seen it somewhere before. My search fu hasn't yielded anything so far.
    – rene
    Jan 26, 2021 at 13:27
  • Probably one of the answers on the announcement post @rene
    – Luuklag
    Jan 26, 2021 at 13:32
  • 1
  • @Catija that looks like a good duplicate candidate, yes.
    – rene
    Jan 26, 2021 at 15:03
  • 1
    And that found me Markdown preview doesn't match post
    – rene
    Jan 26, 2021 at 15:05
  • 1
    I thought I answered one such post and I was right. Unfortunately that was on MSO: meta.stackoverflow.com/a/403577/578411
    – rene
    Jan 26, 2021 at 15:07
  • 1
    Oh, yep. I saw that MSO one, too, @rene
    – Catija
    Jan 26, 2021 at 15:09
  • 2
    This is still broken nearly a year later. I just wasted a lot of time discovering that I needed to insert an empty line before the table, all because the table preview looked just fine. How is it even possible for the preview and the published result to behave differently? Surely they don't have their own personal code for doing the parsing and formatting? Nov 30, 2021 at 13:51
  • 1
    @RayButterworth they do have code for the client renderer and the server renderer. The client code is javascript (hopefully now typescript but that still transpiles back to JS) and the server side is C#. Ideally those two implementations share the same test cases to guarantee the same behavior. Now I welcome you back to the harsh reality ...
    – rene
    May 12, 2023 at 12:59
  • the year is 2023... and the bug is still there ;)
    – gbianchi
    Sep 28, 2023 at 14:51

0

You must log in to answer this question.

Browse other questions tagged .