-
DescriptionI need to render some table rows only when a specific Quarto profile is activated. Here is a simple reproducer: | Variable | Meaning |
|----------------|------------------|
| var1 | some value 1 |
| var2 | some value 2 |
::: {.content-visible when-profile="dummy"}
| var3 | some value 3 |
| var4 | some value 4 |
::: I render it with: But the rendered table is broken because of the empty line due to What is the correct syntax ? Thank you! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 7 replies
-
You can't make half tables and never will be able to do so. Either generate the table programmatically and use the fact that profiles are defined using environment variables or duplicate part of the table. ::: {.content-visible unless-profile="dummy"}
| Variable | Meaning |
|----------------|------------------|
| var1 | some value 1 |
| var2 | some value 2 |
:::
::: {.content-visible when-profile="dummy"}
| Variable | Meaning |
|----------------|------------------|
| var1 | some value 1 |
| var2 | some value 2 |
| var3 | some value 3 |
| var4 | some value 4 |
::: |
Beta Was this translation helpful? Give feedback.
I am not sure to understand.
it's just regular computation with whatever language you want to use.
There is a whole set of guides regarding computations, https://quarto.org/docs/guide/.
And regarding
QUARTO_PROFILE
, it is in the documentation you likely have read since you are using profiles, see https://quarto.org/docs/projects/profiles.html#activating-profiles.