I am writing a manual for some work stuff in Quarto. Some of the pages will include both R and Python. I am wondering if there is a way to automatically label each code chunk with the language in that code chunk. I am currently trying it manually via title
and #| label: R
but neither are outputting anything.
```{python, title="Python"}
1 + 1
```
```{r, title="R"}
#| label: R
1 + 1
```
As you can see below, neither actually appear on the rendered HTML.
I would prefer each cell to have the language labelled something like this:
The exact location within the cell does not matter to me.
Automated would be preferred, but manual is completely acceptable as well.
I am using RStudio with R version 4.4.1, reticulate version 1.38.0, and Python 3.12.4.