viewHTML: Display HTML

View source: R/viewHTML.R

viewHTMLR Documentation

Display HTML

Description

This function displays HTML in the viewer, adding <body> and <head> tags (which should therefore not be included in the fragment).

Usage

viewHTML(x, title = "Psyverse", css = "body {font-size: 16px;}")

Arguments

x

The HTML fragment

title

The title

css

CSS

Value

Invisibly, x, with the extra HTML bits added.

Examples

### Only run this example in an interactive R session,
### as it shows the HTML in the viewer.
if (interactive()) {
  psyverse::viewHTML("<strong>Hello world!</strong>");
}

psyverse documentation built on March 7, 2023, 8:31 p.m.