Lua filters stored in a source package in the
directory will be installed to the
rmarkdown/lua directory in the
package path. This function finds the full paths of the Lua filters in the
pkg_file_lua(filters = NULL, package = "rmarkdown")
A character vector of filenames for Lua filters to be
rmarkdown/lua folder of the package. By default
NULL), if none is provided, it returns all filters in that folder.
The name of the package in which to look for the filters.
A character vector of absolute file paths for the Lua filter from the package. The returned paths have been processed by
pandoc_path_arg(), so they are ready to be used by Pandoc.
# list all Lua filters stored in the rmarkdown package pkg_file_lua() #>  "/home/runner/work/_temp/Library/rmarkdown/rmarkdown/lua/anchor-sections.lua" #>  "/home/runner/work/_temp/Library/rmarkdown/rmarkdown/lua/codefolding.lua" #>  "/home/runner/work/_temp/Library/rmarkdown/rmarkdown/lua/latex-div.lua" #>  "/home/runner/work/_temp/Library/rmarkdown/rmarkdown/lua/number-sections.lua" #>  "/home/runner/work/_temp/Library/rmarkdown/rmarkdown/lua/pagebreak.lua" #>  "/home/runner/work/_temp/Library/rmarkdown/rmarkdown/lua/shared.lua" # get a specific filter pkg_file_lua(c("pagebreak.lua", "latex_div.lua")) #>  "/home/runner/work/_temp/Library/rmarkdown/rmarkdown/lua/pagebreak.lua"