The default blog template and themes on WordPress do not have syntax highlighting enabled by default. I post many code blocks in my post and needed syntax highlight.
I am new to CSS so tried many solutions and found
Prism to be the easiest and working out of the box.
How to Add Syntax Highlights?
- Download CSS code of Prism
- If you are on a premium plan to WordPress, you can create your CSS code for the blog/website.
- Paste the Prism CSS code here. That’s all!