Description Usage Arguments Examples
View source: R/emulate_resolution.R
When developing applications, the display may be different depending on the screen on which the application is displayed. This application allows you to simulate different resolutions to verify that the display is correct.
1 2 3 4 5 6 7 8 9 |
appDir |
The application to run, same as in |
urls |
A vector with URLs to simulate resolution. |
width |
Original width for the iframe containing the application. |
height |
Original height for the iframe containing the application. |
controls |
Display controls widgets to manipulate width/height, URL. Default to |
host |
The TCP port that the application should listen on. See |
port |
The IPv4 address that the application should listen on. See |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | if (interactive()) {
library(shiny)
library(resizer)
# From app directory :
emulate_resolution(
system.file("examples", "01_hello", package = "shiny")
)
# From shiny obj
ui <- fluidPage(
tags$h1("My application")
)
server <- function(input, output, session) {
}
emulate_resolution(
shinyApp(ui, server)
)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.