I'm trying to switch from enumitem
lists to tasks
lists, but the following, which works in an ordinary enumerate
environment, generates a "Something's wrong--perhaps a missing \item" error in the tasks
environment:
\documentclass{article}
\usepackage{tasks}
\newcommand{\itemexpansion}{\item test \item test \item test \item test}
\newcommand{\taskexpansion}{\task test \task test \task test \task test}
\begin{document}
% OK
\begin{enumerate}
\itemexpansion
\end{enumerate}
% Error
\begin{tasks}
\taskexpansion
\end{tasks}
\end{document}
I can tell that there's an expansion problem here, but that's about as far as my comprehension extends. It doesn't seem to match the situations warned about in the manual. Is there a workaround that will allow me to dump the results of a macro (the contents of which are gathered elsewhere) into a tasks
environment?