Doing my own syntax highlighting (finally)

Less rainbow, more readable: fans cheer while purists fume

TLDR: A longtime coding blogger swapped loud rainbow colors for a simpler, calmer look that highlights just a few elements. The community split: minimalists love the clarity, while others argue color should follow workflow needs—sparking a spicy debate over taste, accessibility, and how people actually read code.

After thirteen years of rainbow code, blogger alexwlchan just gave his site’s “syntax highlighting” a minimalist makeover—fewer colors, cleaner lines, and a focus on strings, comments, and names. That’s the color-coding used to make code easier to read, inspired by Nikita Prokopov’s restrained style, and powered by the Rouge tool. The result: a calmer look that fits both light and dark mode—and a comment section that instantly turned into a color war.

Fans shouted finally. One supporter said the new palette “shifts the focus from syntax to logic,” pitching extra ideas like highlighting loops and showing all matches on hover. Minimalists chimed in: “I don’t really need a lot of syntax highlighting,” preferring whitespace and indentation over a Skittles spill. But then came the spicy hot take: “I don’t like this trend copying at all,” with a jab that the original idea came from someone with light sensitivity—cue the eye-rolls and downvotes.

Meanwhile, pragmatists argued this isn’t just about taste, it’s about workflows: some want colors by data type, others by variable name, while another insisted comments deserve VIP treatment because they guide readers. The memes flowed fast—“rainbow goes keto,” “code goth”—and everyone asked the same question: how much color is too much?

Key Points

  • The author replaced a long-standing default syntax highlighting scheme with a simplified, restrained palette.
  • The new design colors only select elements (e.g., names, strings, comments) and leaves most code black/white.
  • Rouge is used to tokenize code and produce HTML spans with classes that map to Pygments-style tokens.
  • CSS targets token classes (e.g., .nf) for styling; code blocks use <pre> with language classes for per-language styles.
  • The updated highlighting works in both light and dark modes and aligns with the site’s color palette.

Hottest takes

"I don't like this trend copying at all. The post he's referring to is probably written by someone with light sensitivity." — foofoo12
"I like to rely on whitespace (blank lines and indentations) more than colors these days." — skydhash
"Color choice is mostly a matter of taste, but highlighting itself is a matter of workflows." — Terr_
Made with <3 by @siedrix and @shesho from CDMX. Powered by Forge&Hive.