# NOT RUN {
if (interactive()) {
library(shiny)
shinyApp(
ui = fluidPage(
useShinyjs(),
textInput("text", "Type something")
),
server = function(input, output) {
showLog()
logjs("App started")
observe({
logjs(paste("Length of text:", nchar(input$text)))
})
}
)
}
# }
Run the code above in your browser using DataLab