Dylan's Advent of Cool Nerd Things Day 10: Fira CodePosted by Dylan Beattie on 10 December 2020 • permalink
Today’s Cool Nerdvent Thing isn’t a tool, or a utility, or a website, or a hidden Windows feature… it’s a font. But not just any font – this font is Fira Code, and it is absolutely the best font ever created for computer programming.
Modern computer font systems like TrueType and OpenType support a feature called ligatures. Ligatures date all the way back to the days of mechanical typesetting and movable type, when printers (as in, people who run printing presses, as opposed to, say, HP Laserjets) would pick a specific glyph to represent common pairs of characters:
You can get lots of fonts that include ligatures for common letter sequences like those above, but Fira Code takes things to a whole new level by using ligatures to replace common programming character sequences with symbols. It’s not the only programming font that uses ligatures – there’s a great article on Better Web Type about monospaced fonts with coding ligatures – but it’s one of the best, and it’s definitely my personal favourite.
Here’s a snippet of F# code using the regular Consolas typeface, and the same code shown in Fira Code:
==’) vs triple-equals (
===), you’ll appreciate how visually distinct Fira Code makes these two character sequences.
Underneath the ligatures, though, there’s a really solid, readable monospaced font, available in various weights for different kinds of editors and displays. Fira Code is released under the SIL Open Font License 1.1, and it’s available as a TrueType TTF file that’ll work on most operating systems, most text editors and programming tools, and it’s available in Open Font WOFF format for use on your website as well.