Plugins
Pandoc Lua filter (upcase-h1.lua) that converts all level-1 headers to uppercase automatically during document processing
September 22, 2025
Samantha Monty
Chair for Human-Computer Interaction, University of Würzburg

A LUA PLUGIN

Meta data

pandoc:
 filters:
  before:
  - upcase-h1.lua

upcase-h1.lua

local text = pandoc.text

function Header(el)
  if el.level == 1 then
    return el:walk {
      Str = function(el)
        return pandoc.Str(
                 text.upper(el.text))
      end
    }
  end
end