Lua filter: use destructured functions for block filters
Filtering functions take element components as arguments instead of the whole block elements. This resembles the way elements are handled in custom writers.
This commit is contained in:
3 files changed
+26
-21
No files matched your search
@@ -1,7 +1,6 @@
|
||||
return {
|
||||
{
|
||||
RawBlock = function (blk)
|
||||
local format, content = unpack(blk.c)
|
||||
RawBlock = function (format, content)
|
||||
if format == "markdown" then
|
||||
return pandoc.reader.markdown.read_block(content)
|
||||
else
|
||||
|
||||
Reference in new issue
Block a user