I entered the default commands for pretitle and posttitle as defined by the documentation for titling to be:
\pretitle{\begin{center}\LARGE}
\posttitle{\par\end{center}\vskip 0.5em}
\preauthor{\begin{center}
\large \lineskip 0.5em%
\begin{tabular}[t]{c}}
\postauthor{\end{tabular}\par\end{center}}
Yet when I do this, I get errors in the form of the red X
next to the line of text from Overleaf, stating
unexpected close group } after \begin{center}
for line 1 and
unexpected open group { after \end{center}
unexpected \end{center}
unexpected close group }
for line 2.
I also do not get the expected results when I edit the posttitle or preauthor commands. However, during compile, there are no error. Is this a problem? If so, how would I fix it?
My entire code is below.
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{hyperref}
\usepackage{titling}
\pretitle{\begin{center}\LARGE }
\posttitle{\par\end{center}\vskip 0.1em}
\preauthor{\begin{center}
\large \lineskip 0.5em%
\begin{tabular}[t]{c}}
\postauthor{\end{tabular}\par\end{center}}
\title{title}
\author{author}
\date{}
\begin{document}
\maketitle
\section{Introduction}
\end{document}