答案1
你可以结合使用与https://tex.stackexchange.com/a/581865/36296带有透明覆盖:
% !TeX program = txs:///arara
% arara: pdflatex: {synctex: on, interaction: nonstopmode, shell: yes}
\documentclass{beamer}
\usepackage{minted}
\setbeamercovered{transparent}
\begin{document}
\begin{frame}[fragile]
\frametitle{Foo}
\begin{minted}[escapeinside=||]{lua}
print("foo")
|\pause|print("bar")
|\pause|print("baz")
\end{minted}
\end{frame}
\end{document}