Skip to content

pandocker/pandoc-docx-pagebreak-py

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pandoc-docx-pagebreak-py

Pandoc filter to insert page break or table-of-contents in docx file

install

pip3 install git+https://github.com/pandocker/pandoc-docx-pagebreak-py

Usage

  • Add \newpage where preferred to insert a page break
    • Expecting to work like native pandoc behavior for latex output
  • Add \toc where preferred to insert TOC(Table of Contents)
    • unable to use with --toc otherwise TOC appears on head of document also
# Try the filter with this file like this:
pandoc -f markdown -t docx -o docx.docx --filter=pandoc-docx-pagebreakpy README.md

Sample

Table of contents appears after this line

\toc

Contents before pagebreak

\newpage

Contents after _Page Break_

Table of contents appears after this line

\toc

Contents before pagebreak

\newpage

Contents after Page Break

About

Pandoc filter to insert pagebreak in docx file

Resources

License

Stars

Watchers

Forks

Packages

No packages published