Programming

highlight.js – syntax highlighter

highlight.js is a syntax highlighter written in JavaScript supporting Node.js and the web.

It works in the browser as well as on the server. It can work with pretty much any markup, doesn’t depend on any other frameworks, and has automatic language detection.

highlight.js can be used in different ways such using CDNs, hosting the bundle yourself, as a Vue plug-in, as ES6 modules, with Node.js, and web workers.

highlight.js works on all modern browsers and currently supported Node.js versions. You’ll need the following software to contribute to the core library:

  • Node.js >= 12.x
  • npm >= 6.x

This is free and open source software.

Key Features

  • 192 languages and 498 themes. There are also 3rd party language definitions available to support even more languages.
  • Automatic language detection.
  • Works with any HTML markup.
  • Zero dependencies.
  • Compatible with any JS framework.
  • Supports Node.js and Deno.

Website: github.com/highlightjs/highlight.js
Support:
Developer: Ivan Sagalaev
License: BSD 3-Clause “New” or “Revised” License

Highlight.js is written in JavaScript. Learn JavaScript with our recommended free books and free tutorials.


Related Software

Syntax Highlighters
PrismLightweight, extensible syntax highlighter, with modern web standards in mind
Highlight.jsJavaScript syntax highlighter with language auto-detection
ShikiThemeable code rendering powered by TextMate grammars
ChromaGeneral purpose syntax highlighter
RougePure Ruby syntax highlighter
PygmentsGeneric syntax highlighter
starry-nightGitHub-style code colouring for JavaScript projects
HighlightTransforms source code into polished, readable output
Re-HighlightPowerful syntax highlighter

Read our verdict in the software roundup.


Best Free and Open Source Software Explore our carefully curated directory of recommended free and open source software, covering every major software category.

The directory forms part of our extensive collection of articles for Linux enthusiasts. It includes hundreds of detailed reviews, together with free and open source alternatives to proprietary software from companies such as Google, Microsoft, Apple, Adobe, IBM, Cisco, Oracle, and Autodesk.

LinuxLinks also covers interesting projects worth exploring, Linux-compatible hardware, free programming books and tutorials, and much more.

Know a useful free and open source Linux application that we haven’t covered? Tell us about it using our submission form.
Subscribe

Please read our Comment Policy before commenting.

Notify of
guest
0 Comments
Oldest
Newest Most Voted