Skip to content

pandoc modifies tex environments #4104

@mtomassoli

Description

@mtomassoli

Consider this minimal tex file:

\documentclass[english]{article}
\begin{document}

\begin{align}
    x &= 3\\
    y &= 2
\end{align}

\end{document}

pandoc test.tex -o test.md produces test.md file with the following content:

$$\begin{aligned}
    x &= 3\\
    y &= 2\end{aligned}$$

If I use a filter, the filter receives aligned rather than align so it's already too late.

The only workaround I found is to wrap the env in $$ but to do that programmatically I'd need to properly parse the tex file.

Is this a bug or what?

I forgot:

pandoc 1.19.2.1
Compiled with pandoc-types 1.17.0.4, texmath 0.9, skylighting 0.1.1.4

on Windows 10.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions