DEV Community


lightweight syntax highlighter for javascript (for blogger)

programmerabhi profile image programmerabhi ・1 min read

Let someone have a lightweight code highlighter. The one that has been claimed that it is lightweight (Prism, Highlight, w3c, etc). I have tried all, there is no lightweight. If you have made your own or are in the project, please share if possible

Discussion (1)

Editor guide
benstigsen profile image
Benjamin Stigsen

I kind of made my own that I'd consider easy to expand and change. It's vanilla JS, but it doesn't include any documentation. Things that get highlighted are determined with regex. It allows you to highlight individual codeblocks or all code blocks at once. It is also compatible with highlightJS conversions and markdown converted codeblocks.