Skip to contents

utility that reconciles/consolidates user-defined params passed via run_app() and default settings from global_defaults_ files

Usage

get_global_defaults_or_user_options(
  user_specified_options = NULL,
  bookmarking_allowed = "url"
)

Arguments

user_specified_options

passed as arguments to run_app()

bookmarking_allowed

same as ?shinyApp enableBookmarking param

Value

a list of global defaults or user options that run_app() uses as the golem_opts parameter in golem::with_golem_options() and that later can be retrieved by server or ui via golem::get_golem_options() or via global_or_param() (which both do almost the same thing).

Details

This function, called by run_app(), collects the shiny-app-related default settings that are defined in these places:

  1. parameters passed to run_app() by a user

  2. settings defined in file global_defaults_shiny_public.R

  3. settings defined in file global_defaults_shiny.R

  4. settings defined in file global_defaults_package.R

and consolidates them all as a list, to be available to server/ui.