shinyAppDir不调整高度

shinyAppDir不调整高度,r,shiny,r-markdown,rstudio,flexdashboard,R,Shiny,R Markdown,Rstudio,Flexdashboard,我正在使用flexdashboard和RMarkdown创建应用程序。但是,应用的高度不会相应地或按照规定的测量值变化 --- title: "Flexdashboard not adjusting height" output: flexdashboard::flex_dashboard: orientation: rows social: menu runtime: shiny --- ```{r, height=850} lib

我正在使用
flexdashboard
RMarkdown
创建应用程序。但是,应用的高度不会相应地或按照规定的测量值变化

---
title: "Flexdashboard not adjusting height"
output: 
  flexdashboard::flex_dashboard:
    orientation: rows
    social: menu
runtime: shiny
---
    
    
```{r, height=850}
library(shiny)
shinyAppDir(
  system.file("examples/06_tabsets", package="shiny"),
  options = list(height=850)
)
```
## Another
我包括了高度选项,但它通过滚动条加载(我的RStudio会话如下所示)


将您的R更新到最新版本可能会解决您的问题,您的代码在我的机器上运行,而不会出现您的问题。还可以使用“创建干净的环境”在新目录中打开新项目。您的web浏览器是否设置为缩放~150%


另一种解决方法是使用
CSS3
as,并添加了
fluidRow
100vh
样式

---
title: "Flexdashboard not adjusting height"
output: 
  flexdashboard::flex_dashboard:
    orientation: rows
    social: menu
runtime: shiny
---

```{r , height = "100%"}
library(shiny)
fluidRow(style = " overflow: auto;  height: calc(100vh - 50px) !important;",
shinyAppDir(
  system.file("examples/06_tabsets", package="shiny"))
)
```

您是否尝试过在浏览器中打开它?有时Rstudio会做一些有趣的事情。我试过浏览器,但仍然是一样的,我认为这是Rstudio版本的问题。您使用的是哪个版本的RStudio?我从1.4版降级到了1.1.463版。应用程序运行良好。这会受到
pandoc
版本的影响吗?这两个版本不同,
RStudio 1.4.*
中的
pandoc 2.11.4
RStudio 1.1.463中的
pandoc 1.19.2.1
。我试着从
R
GUI运行这个应用程序,pandoc路径设置为
Sys.setenv(RSTUDIO_pandoc=“C:\Program Files\RSTUDIO\bin\pandoc”)
,区别在于我不认为flexdashbaords使用pandoc,pandoc只用于PDF输出,我认为这更像是Rmarkdown的呈现
---
title: "Flexdashboard not adjusting height"
output: 
  flexdashboard::flex_dashboard:
    orientation: rows
    social: menu
runtime: shiny
---

```{r , height = "100%"}
library(shiny)
fluidRow(style = " overflow: auto;  height: calc(100vh - 50px) !important;",
shinyAppDir(
  system.file("examples/06_tabsets", package="shiny"))
)
```