log_init: Initialize logging to JavaScript console

Description Usage Value Examples

View source: R/log_init.R

Description

log_init should be put into the shiny ui to initialize JavaScript code that enables logging to JavaScript console in an Internet browser.

Usage

1

Value

A tagList with script tag inside head tag.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
if (interactive()) {
  set_logging(js_console = TRUE)
  shiny::shinyApp(
    ui = shiny::fluidPage(log_init()),
    server = function(input, output) {
      set_logging_session()
      log_event("See browser JavaScript console (CTRL + SHIFT + I)")
    }
  )
}

shinyEventLogger documentation built on May 1, 2019, 9:26 p.m.