I tried to convert a Latex document with pandoc in html and I get the following error:
unexpected
\lstinputlisting[
Is it possible to use \lstinputlisting with Pandoc?
My code main.tex as follows:
\usepackage{listings}
\lstinputlisting[
float,
language=Java,
caption={My very first program in Java},
label={lst:helloworld},
]{listings/HelloWorld.java}
in \Cref{lst:helloworld}, we describe an hello world program in Java.
I solved adding
--listings
to Pandoc conversion and removing the new lines in the arguments. Looks like Latex can interpret them but not Pandoc.