On that subject: it would be really nice if font creators also care whether the fonts render well without needing anti-aliasing / font smoothing. Some websites are completely unreadable because the fonts don't render correctly without anti-aliasing.
Absolutely true.
The
Web Open Font Format (version 1,
.woff, supported by now by even pretty old browser versions, and version 2
.woff2 by all current versions) contain the TrueType/OpenType font as-is in compressed format, plus some XML information about it. That means if the font is hinted, hinting is available to the browser rendeder. (Most browsers do apply cross-origin CSS policy, meaning the web fonts have to reside in the same domain as the HTML pages used; that's why just referring to some central web repository won't work well. Also, the set of glyphs included in the web font
can be trimmed down, so you generally want to make sure you have the full font, and not someones idea of what is the useful set of glyphs from the full font typeface.)
Most fonts have been designed for printing (high-resolution devices), and only some –– Noto, DejaVu, FreeFont in particular! –– for displays ("low-resolution" devices, in this context)
and with wide Unicode coverage.
(Some older fonts, like Monaco (on Mac) and Verdana (on Windows)
were designed for displays, and often have very good hinting so they render well even without bitmap versions and antialiasing, but they were designed at a time when only a much smaller subset of glyphs were used: for older character encodings like
MacRoman,
Windows-1252 and
code page 437.)
I did start a new
thread in News/Suggestions/Help forum, with an example of how Dave could ensure that code snippets and teletyped text would show up the same way in all browsers regardless of what fonts the user has installed.
I do believe DejaVu Sans Mono is quite legible down to small sizes, although for the very smallest sizes (8×14 pixels for example) bitmap monospace fonts can be even better.
The same applies to
all web sites, and TrueType and OpenType fonts that are licensed, or one has a license to, use on ones own web site. So it is definitely not difficult, just a few minutes work. The
actual work is in choosing the font in the first place, such that it indeed is rendered well on all sorts of devices, and not just on the graphic artist's perfectly color-calibrated 3840×2160 retina display in a perfectly-lit office!
All that does relate to code comments, in the sense that whoever is reading the code comments, is often approaching the source codebase from a different direction than the designer/author/developer team. Compare the situation to a graphic designer: they very often focus on what is stylish and visually pleasing, as opposed to what is functional on many different types of devices (including window sizes and resolutions). For web pages,
responsive web design is the counterbalance for that.
For code, I do believe good code comments are similar counterbalance against "if it
seems to work, don't care and don't touch it", related to
maintainability; specifically against the "seems to work" part. If we know the developer intent/purpose for some chunk of code, for example noted in a short useful comment, we can compare that to the actual code, and qualitatively evaluate the "seems to work" part.
For example, when fixing simple bugs, such qualitative evaluation helps pinpoint suspicious code: I personally focus first on code that differs most from its apparent/ostensible purpose (including comments).
That also means that I believe that when one does such code review, one should be ready and willing to update, add, and remove comments,
even though it provides no functional changes at all. Just like "responsive web design" is separate from plain old "graphic design", we developers should consider code review, analysis, and comment updating a separate valued/useful task we should regularly do.