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

Charts not being loaded using flexdashboard and rmarkdown (>= 1.11) #29

Open
koolmees opened this issue Jun 14, 2022 · 2 comments
Open

Comments

@koolmees
Copy link

Hi,

Using this simple example, I am receiving an empty screen upon opening the html document:

---
title: "Untitled"
output: 
  flexdashboard::flex_dashboard:
    orientation: columns
    vertical_layout: fill
---

```{r setup, include=FALSE}
library(flexdashboard)
```


```{r, echo = FALSE}
library("billboarder")

# data
data("prod_par_filiere")

# a bar chart !
billboarder() %>%
  bb_barchart(data = prod_par_filiere[, c("annee", "prod_hydraulique")], color = "#102246") %>%
  bb_y_grid(show = TRUE) %>%
  bb_y_axis(tick = list(format = suffix("TWh")),
            label = list(text = "production (in terawatt-hours)", position = "outer-top")) %>% 
  bb_legend(show = FALSE) %>% 
  bb_labs(title = "French hydraulic production",
          caption = "Data source: RTE (https://opendata.rte-france.com)")
```

Using Pandoc 2.6:

> xfun::session_info("rmarkdown")
R version 4.1.0 (2021-05-18)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 19044), RStudio 1.2.1335

Locale:
  LC_COLLATE=English_United States.1252  LC_CTYPE=English_United States.1252    LC_MONETARY=English_United States.1252 LC_NUMERIC=C                          
  LC_TIME=English_United States.1252    

Package version:
  base64enc_0.1.3 bslib_0.3.1     digest_0.6.29   evaluate_0.15   fastmap_1.1.0   fs_1.5.2        glue_1.6.2      graphics_4.1.0  grDevices_4.1.0 highr_0.9       htmltools_0.5.2 jquerylib_0.1.4
  jsonlite_1.8.0  knitr_1.39      magrittr_2.0.3  methods_4.1.0   R6_2.5.1        rappdirs_0.3.3  rlang_1.0.2     rmarkdown_2.14  sass_0.4.1      stats_4.1.0     stringi_1.7.6   stringr_1.4.0  
  tinytex_0.39    tools_4.1.0     utils_4.1.0     xfun_0.31       yaml_2.3.5     

Pandoc version: 2.6

The people from rmarkdown were able to find the following:
image

This only happens with rmarkdown versions 1.11 and onwards. Could you please look into this from the JS side of things, to identify what causes this issue to happen?

Possible more information in my original topic: rstudio/rmarkdown#2378

@pvictor
Copy link
Member

pvictor commented Sep 1, 2022

Sorry for late answer but I have no idea why this isn't working with this specific widget. I think this is CSS related..
I corrected the error you mentionned, but no positive effect.

@pvictor
Copy link
Member

pvictor commented Nov 3, 2022

Ok I still don't know why the graphics don't render but I found a workaround, it should work now. Please re-install from GitHub.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants