Adding a Little Style

I have never really liked the default code blocks in WordPress. So I went looking to find a better plugin… Then I went looking again.

Round 1

I literally went into WordPress’ Plugins section, clicked on Add New, and searched for syntax. For whatever reason, I landed on SyntaxHighlighter Evolved, and it seemed like it fit the bill.

So, I installed it, and went through the process of finding all my wp-code blocks so that I could convert them. That was a slightly laborious task, as I had to get the list from the database and then click through and edit. Sure, I could have probably wrote a small application to make the replacement. I only have 35 posts with code blocks, and I figured I’d only do it once, so I did it by hand.

6 hours later…

I hated it. I like the dark theme of my site, so the giant white blocks of goo on page were very intrusive. Language support was decent, but missing some of my favorites (including Dockerfile and HCL).

A more detailed Google search lead me to Code Block Pro. Before I went through 35 posts replacing code blocks, though, I decided to test this one a bit more. The language list is extensive, and there are a bunch of included themes. There are a few dark themes, and GitHub Dark seems to fit fairly well into the site style.

A bit more confident of my new choice, I went back through those 34 posts and replaced the SyntaxHighlighter Evolved blocks with Code Block Pro blocks. I am starting the stopwatch to see if this one makes it longer than 6 hours.


Posted

in

by

Tags:

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *