wikiti / pandoc-book-template

A simple Pandoc template to build documents and ebooks.
MIT License
392 stars 89 forks source link

Page break after table of contents? #17

Closed alexispurslane closed 3 years ago

alexispurslane commented 3 years ago

I would like to start a new page after the table of contents, in order to format this more like a real book. I tried to edit the template to add a \newpage or \pagebreak but that didn't work. Is there a way to do this?

wikiti commented 3 years ago

Hi @christopherdumas,

I'm assuming you're exporting to PDF (latex). You may want to modify the template file, located at templates/pdf.latex. I've make a simple change, and it seems page breaks are working properly:

diff --git a/templates/pdf.latex b/templates/pdf.latex
index 4ceca43..442192f 100644
--- a/templates/pdf.latex
+++ b/templates/pdf.latex
@@ -409,6 +409,7 @@ $if(beamer)$
 \frame{\titlepage}
 $else$
 \maketitle
+\newpage
 $endif$
 $if(abstract)$
 \begin{abstract}
wikiti commented 3 years ago

Hello @christopherdumas,

Without your response, I assume that the issue is solved. Please feel free to comment on this same issue, or create a new one.