diff options
| author | Albert Krewinkel <[email protected]> | 2024-10-01 12:08:00 +0200 |
|---|---|---|
| committer | Albert Krewinkel <[email protected]> | 2024-10-01 12:23:36 +0200 |
| commit | 4cf6ddb027cdc262e34dea50ec77f3fcdbc517d2 (patch) | |
| tree | c253d35d84b05c4eacffd4171be211e726602d1b /pandoc-lua-engine/src/Text/Pandoc/Lua/Module/Utils.hs | |
| parent | 752d57dac18b2381fb05972cccdc21ea16d242cd (diff) | |
Lua: allow returning a single filter from filter files
It is now possible to return a single filter from a filter file, e.g.
``` lua
-- Switch single- and double quotes
return {
Quoted = function (q)
elem.quotetype = elem.quotetype == 'SingleQuote'
and 'DoubleQuote' or 'SingleQuote'
return elem
end
}
The filter must not contain numerical indexes, or it might be treated as
a list of filters.
Diffstat (limited to 'pandoc-lua-engine/src/Text/Pandoc/Lua/Module/Utils.hs')
0 files changed, 0 insertions, 0 deletions
