html_asis: Escape HTML strings

Description Usage Arguments Value Examples

View source: R/shiny-flex-div.R

Description

Escape HTML strings so that they will be displayed 'as-is' in websites.

Usage

1
html_asis(s, space = TRUE)

Arguments

s

characters

space

whether to also escape white space, default is true.

Value

An R string

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
ui <- flex_div(
  shiny::textInput('id', ' ', width = '100%',
                   value = 'Height not aligned'),
  actionButtonStyled('ok', 'Button1', width = '100%',),
  shiny::textInput('id2', html_asis(' '), width = '100%',
                   value = 'Heights aligned'),
  actionButtonStyled('ok2', 'Button2', width = '100%',),
  ncols = 2
)
if(interactive()){
  shiny::shinyApp(ui = shiny::fluidPage(shiny::fluidRow(ui)),
                  server = function(input, output, session){})
}

dipsaus documentation built on Sept. 6, 2021, 5:08 p.m.