Reputation: 877
I'm trying to create a valuebox but my problem is that the subtitle text is too long.
Here is my code
```{r}
valueBox(12,
paste('Number of Cars',':','City','is Chicago'))
```
But my Goal would be something like this
I tried using "\n" but it didn't work.
Upvotes: 1
Views: 1226
Reputation: 3252
I used paste0()
instead, I was able to do this using HTML linebreak code <br>
. I think it might depend if you are using flexdashboard, or shiny. But this should help hopefully.
---
title: "Old Faithful Eruptions"
output: flexdashboard::flex_dashboard
runtime: shiny
---
```{r}
flexdashboard::valueBox(42, paste0('Number of Cars',':','<br>','City ','is Chicago'))
```
Upvotes: 2