Edit and export syntax highlighted code from code-server
Find a file
2025-10-18 19:24:46 +00:00
chromium initial commit 2025-10-18 19:24:46 +00:00
LICENSE initial commit 2025-10-18 19:24:46 +00:00
README.md initial commit 2025-10-18 19:24:46 +00:00

Export syntax highlighting from code-server

Most syntax highlighting libraries on the web try to implement their own parser, often with mixed results. This is an extension for Chromium-based browsers that allow you to edit and export code with syntax highlighting using a real language server from code-server. Code-server is a fork of Visual Studio Code that runs entierly in the browser or as a PWA.

Any language supported by code-server (VSCode) either built in or with an extension is supported. The markdown generated by code-server is exported as raw HTML with classnames on spans that determine syntax highlighting. This extension also allows you to edit the syntax highlighting of your code before exporting.

Installation

  1. Download the latest .crx file here
  2. Navigate to chrome://extensions/
  3. Enable "Developer mode" (top right corner of the page)
  4. Drag and drop the .crx file you downloded in step 1 onto this page

Other features

Besides just exporting code from code-server, this extension comes with an editor that can be used to change various things before exporting.

Change color and text

Text and syntax highlighting color can be changed.

Split and join spans

The spans which control which color text should have can be split at the cursor to create another span which can be formatted seperately. Seperate spans can also be merged by joining together with a span to the left of the target span.

Highlight and delete spans

All spans can be highlighted for an easier overview. Empty spans (no innerText at all) are automatically highlighted and can be removed by joining to the left.