当我们运行以下代码时,正在反映对 gt 表的字体更改
mtcars%>%
head()%>%
gt()%>%
opt_table_font(
font="Georgia"
)
但是,当使用 R 闪亮的应用程序运行相同的事情时,字体不会正确反映
library(shiny)
library(gt)
ui <- fluidPage(
gt_output("table")
)
server = function(input, output, session) {
output$table <- gt::render_gt({
data<-mtcars%>%
head()%>%
gt()%>%
opt_table_font(
font="Georgia"
)
}
)
}
shinyApp(ui, server)