AnkiWeb
- Rating
- 17 (👍 14 · 👎 3)
- Updated
- 2024-02-20
- Anki versions
- 23.12.1~
- Description language
- en
AnkiWeb addon 1415523481
Adds non-invasive syntax highlighting to pre code blocks in Anki cards, auto-detecting languages with options to specify language and customize font size and color scheme.
Open on AnkiWeb GitHub Ask about alternatives
abandoned
| Min Anki | Max Anki | Updated |
|---|---|---|
| 23.12.1 | + | 2024-02-20 |
Loading…
Renders flashcards with advanced markdown, LaTeX math, syntax highlighting, theme-aware styling, tag badges, and interactive cloze toggles via React components.
Adds an integrated CodeMirror code editor to Anki flashcards with syntax highlighting, themes, live preview, configurable languages and note types, and mobile highlighting.
Inserts syntax-highlighted code snippets into Anki notes, with language selection, configurable line numbers, centering, CSS classes, and per-deck language memory.
Creates highlighted code blocks and inline code from selected text or clipboard, working in day and night modes on Anki desktop and AnkiDroid.
Quickly adds syntax highlighting to selected or pasted code in Anki's editor, with line numbers, CSS themes, font size, hotkeys, and per-deck language memory.
Converts single and triple backticks in Anki's editor into HTML code tags, supporting language classes for blocks and syntax-highlighter integration.
Code highlighting for Anki.

In the note editor, click the <> button and enclose your code in <pre><code> ... </code></pre>. In the previewer and reviewer, code highlighting will be applied automatically.
By default, the programming language is auto-detected. You can manually specify the language editing the class attribute e.g. <code class="language-cpp">. Look in highlightjs/languages for the list of language codes you can choose from. Consider doing this if auto-detecting takes too long (makes the reviewer lag).
anki-code-highlight is non-invasive; it doesn't modify your original note to add the highlighting. If you disable or uninstall anki-code-highlight, your pre code blocks just return to being normal pre code blocks.
You can change the font size in the config file. Any valid CSS font-size property is valid in this field.
The color scheme can changed by setting the config file. Look in highlightjs/styles for the list of color schemes you can choose from.
Distributed under the MIT license. See LICENSE.txt for more information
Uses highlight.js, included under the BSD 3-Clause license. See highlightjs/LICENSE file for license details.