logoalt Hacker News

Spunkietoday at 2:03 AM2 repliesview on HN

I've not much to say on the thermal printer part of this but the extensions they did to markdown are great. They had me double taking for a few seconds thinking they might be real markdown because they make so much sense.

    [align=center]    Center-align the following text (also left, right)
    [qr=https://...]  Generate and print a QR code
Deprecating align in html was a mistake.

Replies

xp84today at 3:35 AM

It’s funny, after all the work that was done to decouple content from presentation, 90% of the markup I’ve seen in every codebase this decade is using Styled Components anyway, which commingles them in the source code anyway.

show 2 replies
sheepttoday at 8:39 AM

Since align is only deprecated and not removed, and Markdown is a superset of HTML (at least for CommonMark and GFM), it would be valid markdown to just use <div align=center> to center text (not like there's such a thing as invalid Markdown)