On my browser, the
Show code snippet link for the code snippet
alert("This is some example code");
renders as follows:
It looks like the line and the text are in separate elements, allowing the text to be drawn above the line. Moving
text-decoration: underline from the surrounding
<a> tag to the
<span> tag fixes the problem for me.
vertical-align: middle; from the inner
<span> works just as well.
I use Firefox 77.0 64-bit on Windows 10, without any extensions. In Chrome >=80.0, it renders correctly.