From 6e872a8468a5395c1b7f3299d7b6a46440ecf42e Mon Sep 17 00:00:00 2001 From: Jay Hesselberth Date: Thu, 16 May 2024 08:36:42 -0600 Subject: [PATCH] Add alt text to vignette (#2546) Co-authored-by: Hadley Wickham --- vignettes/test/rendering.Rmd | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/vignettes/test/rendering.Rmd b/vignettes/test/rendering.Rmd index 705b3da527..3bea6e676d 100644 --- a/vignettes/test/rendering.Rmd +++ b/vignettes/test/rendering.Rmd @@ -5,7 +5,8 @@ author: "Author is skipped from the TOC" date: "Date is skipped from the TOC" --- -```{r include = FALSE} +```{r} +#| include: FALSE knitr::opts_chunk$set(collapse = TRUE, comment = "#>") ``` @@ -20,6 +21,7 @@ Yay[^footnote] ## Figures ```{r} +#| fig.alt: Test plot plot(1:10) ``` @@ -30,7 +32,7 @@ x <- readLines("test.txt") x ``` -![](bacon.jpg) +![bacon](bacon.jpg) ## Details tag @@ -122,7 +124,8 @@ warning(cli::style_bold("This is bold")) ``` Some text -```{r, error = TRUE} +```{r} +#| error: TRUE stop(cli::style_italic("This is italic")) ``` @@ -170,6 +173,7 @@ blop something nice ```{r} +#| fig.alt: Another test plot plot(1:42) ```