### Bug description

The function `profvis::profvis()`, somehow, messes up the syntax highlighting of R code blocks.

## Example

File:

````Rmd
---
format: html
---

```{r}
library(profvis)

f <- function() {
  pause(0.1)
}

# profvis(f())
```
````

Normal syntax highlighting:

![2023-01-16_22-30_1](https://user-images.githubusercontent.com/4634851/212826982-703d5f36-32da-4416-887f-b17ad1a6869b.png)

With `profvis::profvis()`:

````Rmd
---
format: html
---

```{r}
library(profvis)

f <- function() {
  pause(0.1)
}

profvis(f())
```
````

Syntax highlighting totally messed up:

![2023-01-16_22-30_2](https://user-images.githubusercontent.com/4634851/212826353-b17f6799-2313-41c5-86b1-25f0db10fcfd.png)

## Context

Same behaviour with any highlight style, with `format: revealjs` and `format: html`, within a website or outside.

*Note: this might be something weird that the function is doing and may not be a Quarto bug per se.*

## OS

Arch Linux (6.1.6-arch1-1)

### Checklist

- [x] Please include a minimal, fully reproducible example in a single .qmd file? Please provide the whole file rather than the snippet you believe is causing the issue.
- [x] Please [format your issue](https://quarto.org/bug-reports.html#formatting-make-githubs-markdown-work-for-us) so it is easier for us to read the bug report.
- [ ] Please document the RStudio IDE version you're running (if applicable), by providing the value displayed in the "About RStudio" main menu dialog?
- [x] Please document the operating system you're running. If on Linux, please provide the specific distribution.
2023-01-17T06:46:04Z
prosoitos
bug
closed
Syntax highlighting messed up by profvis::profvis()
https://github.com/quarto-dev/quarto-cli/issues/3991