Installed vignettes show blank tables/plots: self_contained: no drops lt assets on R CMD build
Los mantenedores suelen responder en 2 días
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 84/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- markdown, r
- Área
- documentation
Línea de trabajo
Actualiza los encabezados YAML de las 10 viñetas HTML afectadas que se enumeran en el issue, cambiando self_contained: no por yes. Empieza comprobando una de las viñetas enumeradas y confirma que las 10 tienen la misma configuración; luego ejecuta R CMD build . e inspecciona los inst/doc/*.html generados. El trabajo estará terminado cuando el HTML de la viñeta instalada incluya los recursos necesarios y se rendericen las tablas y las figuras.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Problem
After R CMD build + R CMD INSTALL, opening the installed vignette .html files (inst/doc/*.html) in a browser shows no tables or plots — the interactive AE forest tables and the dot-plot/error-bar figures are missing. The prose renders, but the table area is blank.
Root cause
Every HTML vignette sets self_contained: no in its YAML header:
output:
rmarkdown::html_document:
self_contained: no
With self_contained: no, pandoc writes the lt JS/CSS (and other web dependencies) into a <vignette>_files/ sidecar directory and references them with relative <script src="..._files/lt-x.y.z/lt-interactive.js"> tags. R CMD build strips these _files/ sidecar directories from the built package, so the installed .html points at assets that do not exist. No JS loads, and since the lt table is built entirely client-side from an embedded spec, nothing renders.
This is preexisting but only became visible once all table/figure rendering moved to client-side JS (lt); the old static-image paths masked it.
Reproduction
R CMD build .then extract the tarball.inst/doc/customize-color.htmlreferencescustomize-color_files/lt-*/lt-interactive.js.- No
*_files/directory exists anywhere in the build. - Open the installed
.htmlin a browser → blank table.
Verification
- Standalone render opened directly in a browser works (deps resolve from the local
_files/), which is why this is easy to miss duringrmarkdown::render()dev loops. - Headless check of the built-tarball
inst/doc/customize-color.htmlconfirms the table does not mount.
Fix
Set self_contained: yes (the rmarkdown default) in the affected vignettes so pandoc inlines all JS/CSS into a single standalone .html. The lt assets are small (the old reactable+plotly bulk that likely motivated self_contained: no is gone), so inlining is cheap.
Verified: with self_contained: yes, R CMD build produces inst/doc/*.html with zero external _files/lt references and no sidecar directory; a headless browser renders the table (10 rows) and all 42 inline SVG figures with no JS errors.
Affected files (all 10 HTML vignettes carrying self_contained: no):
customize-ae-specific-columns, customize-color, customize-diff-label, customize-digits, customize-display-only-soc, customize-listing-columns, customize-toggle-buttons, customize-width, customize-xlimit, forestly.
(design-pattern.Rmd uses html_vignette and is unaffected; both forestly.Rmd and design-pattern.Rmd are in .Rbuildignore, so they are not shipped as installed vignettes anyway.)
- Lenguaje dominante
- R
- Estrellas
- 23
- Forks
- 6
- Merge medio
- 2 d 9 h
- PR fusionados (30 d)
- 12
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de Merck/forestly
-
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
Los mantenedores suelen responder en 2 días
-
Allow numerical filtering for percentagesPosiblemente ocupada @yihui la tomó hace 8 días. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 25/100
Merck/forestly#166 · 1 asignado ·
Los mantenedores suelen responder en 2 días
-
Add `ae_listing_label = ...` to `prepare_ae_forestly()`Posiblemente ocupada @fukuhiro2023 la tomó hace 19 días. Abierto
Merck/forestly#152 · 1 asignado ·
Los mantenedores suelen responder en 2 días
-
A lot of if-else in `format_ae_listing()`Posiblemente ocupada @fukuhiro2023 la tomó hace 21 días. Abierto
Merck/forestly#148 · 1 comentario · 1 asignado ·
Los mantenedores suelen responder en 2 días
-
Dificultad 3/5 1-2 días Aptitud para principiantes 65/100
Los mantenedores suelen responder en 2 días
Todos los issues de Merck/forestly
Issues similares
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 75/100
hturner/pkg-dev-ctv#57 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 3 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
datacarpentry/semester-biology#1272 ·
Los mantenedores suelen responder en 1 día
-
[docs] Make tests more efficientAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100