【发布时间】:2020-11-04 09:53:30
【问题描述】:
我从 bootswatch (https://bootswatch.com) 下载了一个 css,并将文件 (bootstrap.css) 保存在我的 flexdashboard 文件所在的位置。所以我尝试用这段代码加载css:
---
title: "Untitled"
output:
flexdashboard::flex_dashboard:
orientation: columns
vertical_layout: fill
css: bootstrap.css
---
```{r setup, include=FALSE}
library(flexdashboard)
```
Column {data-width=650}
-----------------------------------------------------------------------
### Chart A
```{r}
```
但是 css 没有加载。我想使用 Bootswatch 的“Mint”主题。请问,你知道这个问题的解决方案吗?提供的任何帮助将不胜感激。
【问题讨论】:
-
我不相信您的 .css 文件位于正确的位置,如果您要在此代码示例中使用它,它需要与您的 flexdashboard 位于同一目录中
-
你好@DanielJachetta,是的,它在同一个目录中,我什至检查了它以使其成为工作目录。
-
@Alexis,你的 R 版本是多少?
-
你好@Waldi,R 版本是 3.6.1
标签: css r shiny r-markdown flexdashboard