Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[quarto] disable_processing options should opt-out fmt_markdown specific output for quarto #1488

Closed
cderv opened this issue Nov 10, 2023 · 1 comment · Fixed by #1688
Closed

Comments

@cderv
Copy link
Collaborator

cderv commented Nov 10, 2023

---
title: "Test"
format: html
keep-md: true
---

```{r}
library(gt)
data.frame(A = "Text", B = '<em class="special">Text</em>') |> 
  gt() |> 
  tab_options(quarto.disable_processing = TRUE) |> 
  fmt_markdown(B)
```

image

You can see the weird output in the column. This is related to

and found while looking at

Content produced is still quarto specific

<div data-qmd="<em class="special">Text</em>">

but disabling quarto processing should have prevented inserting the data-qmd attributes.

There are other way to achieve that, but still I believe data-qmd insertion is tied to quarto table processing. So deactivating it when option is present seems better.

What works

fmt_passthrough() works though.

```{r}
library(gt)
data.frame(A = "Text", B = '<em class="special">Text</em>') |> 
  gt() |> 
  tab_options(quarto.disable_processing = TRUE) |> 
  fmt_passthrough(B, escape = FALSE)
```
@rich-iannone
Copy link
Member

This should be solved by fixing #1487.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment