#9999·jekyll

[Bug]: `kramdown.syntax_highlighter: nil` (or `false`) in `_config.yml` does not disable syntax highlighting; silently falls back to `rouge`

Author: pbrehenyCreated Jul 7, 2026Updated Jul 11, 2026

Operating System

Ubuntu 24.04

Ruby Version

ruby 3.2.3 (2024-01-18 revision 52bb2ac0a6) [x86_64-linux-gnu]

Jekyll Version

jekyll 4.4.1

GitHub Pages Version

Latest

Expected Behavior

If you turn off syntax highlighting in Jekyll's _config.yml:

kramdown:
  syntax_highlighter: null

I would expect that syntax highlighting is turned off.

Current Behavior

Output is still fully Rouge-highlighted (<div class="language-r highlighter-rouge">...).

Relevant log output

Code Sample

  • Jekyll 4.4.1, kramdown 2.4.0, kramdown-parser-gfm 1.1.0, Ruby 3.2.3
  • _config.yml:
    markdown: kramdown
    kramdown:
      input: GFM
      syntax_highlighter: null
    
  • Any page with a fenced code block (```ruby) still renders with full highlighter-rouge markup instead of plain <pre><code class="language-ruby">.

Note that this is a Jekyll bug, not a kramdown bug. If you call Kramdown directly with Kramdown::Document.new(md, syntax_highlighter: nil), the output is correct (plain). The bug is in Jekyll's config-merging wrapper, not kramdown.