Code Syntax Highlighting

Hey there! If you’re looking for a quick way to highlight code on your web pages, check out this link: https://github.com/vespaiach/prismjs-loader

Introduction

While searching for a library to highlight code on my web pages, I came across Highlight.js—a well-known, easy-to-integrate, and well-documented library. Everything seemed great until I discovered that Highlight.js doesn’t support JSX.

I did another Google search and found that Prism.js does support JSX. After spending about 10 minutes skimming through its integration documentation, I realized that the process wasn’t immediately clear to me. So, I searched again for ways to integrate Prism.js and stumbled upon the PrismJS Loader repository.

Turns out, all I had to do was copy and paste the link mentioned in the repository’s README page—and that was it!

Super simple. Huge shout-out to the author of PrismJS Loader!