The use of tags in UI.R
tags
is an object of type list that is automatically generated inside Shiny applications, which enables the insertion of HTML tags within a user interface generated in UI.R
. This basically contains a list of functions that will transform the string argument to the content of the tag used, for example, see the following:
tags$pre("Text inside a pre tag")
This generates the following tag:
<pre>Text inside a pre tag</pre>
Note
The complete list of tags can be found at http://shiny.rstudio.com/articles/tag-glossary.html.
Attributes can be passed to any of the functions in tags by passing them as arguments, for example:
tags$pre(align="right","Text inside a pre tag")
This will be turned into the following HTML:
<pre align="right">Text ...
Get Learning Shiny now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.