I've got a Stan model that I'd like to include in a Quarto doc (without copying/pasting code over). Currently, I can do this with:
```{r}
writeLines(readLines("model.stan"))
This gives the stan code, but formatted as a character string output from R --- is there a way to apply Stan's syntax highlighting to the output? This gives an example of outputting bash formatting, but I've been unable thus far to recreate with stan.
Try with the chunk option
#| class-output: stanand usecat(readLines("<filename.ext>"), sep = "\n").However, in Quarto there is a more easy way to do that using the quarto extension
include-code-files.output
test.stan