我有一篇非常简单的文章,内容如下:
\documentclass{article}
\usepackage{appendix}
\begin{document}
\tableofcontents
\appendixtitleon
\appendixtitletocon
\section{Writing}
\begin{appendices}
\section{First appendix}
\subsection{First}
\subsection{Second}
\section{Second appendix}
\subsection{First}
\subsection{Second}
\end{appendices}
\end{document}
答案1
添加[toc]
选项:
\documentclass{article}
\usepackage[toc]{appendix}
\begin{document}
\tableofcontents
\appendixtitleon
\appendixtitletocon
\section{Writing}
\begin{appendices}
\section{First appendix}
\subsection{First}
\subsection{Second}
\section{Second appendix}
\subsection{First}
\subsection{Second}
\end{appendices}
\end{document}