Launch app

Function run_dev() will execute the content of dev/run_dev.R and launch the application

run_dev()

Run run_dev.R

Create files

These functions create files inside the inst/app folder. These functions can be used outside of a golem project.

add_js_file() add_js_handler() add_js_input_binding() add_js_output_binding() add_css_file() add_sass_file() add_html_template() add_partial_html_template() add_ui_server_files()

Create Files

Create a Dockerfile

Build a container containing your Shiny App. add_dockerfile() creates a “classical” Dockerfile, while add_dockerfile_shinyproxy() and add_dockerfile_heroku() creates platform specific Dockerfile.

add_dockerfile() add_dockerfile_shinyproxy() add_dockerfile_heroku() add_dockerfile_with_renv() add_dockerfile_with_renv_shinyproxy() add_dockerfile_with_renv_heroku()

Create a Dockerfile for your App

Use files

use_external_js_file and use_external_css_filedownload files from external sources and install them inside the appropriate directory. use_utils_ui copies the golem_utils_ui.R to the R folder and use_utils_server copies the golem_utils_server.R to the R folder.

use_external_js_file() use_external_css_file() use_external_html_template() use_external_file() use_internal_js_file() use_internal_css_file() use_internal_html_template() use_internal_file()

Use Files

use_utils_ui() use_utils_test_ui() use_utils_server() use_utils_test_ui() use_utils_test_server()

Use the utils files

Add fct_ and utils_ files

Add fct_ and utils_ files

add_fct() add_utils()

Add fct_ and utils_ files

Add an app.R

Add an app.R at the root of your package to deploy on RStudio Connect

add_rstudioconnect_file() add_shinyappsio_file() add_shinyserver_file()

Add an app.R at the root of your package to deploy on RStudio Connect

Mode detection

Is the app in dev mode or prod mode?

app_prod() app_dev()

Is the app in dev mode or prod mode?

Dev dependent functions

This functions will be run only if golem::app_dev() returns TRUE.

cat_dev() print_dev() message_dev() warning_dev() browser_dev()

Functions already made dev dependent

Test helpers

These functions are designed to be used inside the tests in your Shiny app package.

expect_shinytag() expect_shinytaglist() expect_html_equal() expect_running()

Test helpers

Favicon functions

This function adds the favicon from ico to your shiny app.

use_favicon() remove_favicon() favicon()

Add a favicon to your shinyapp

Addins

insert_ns() takes a selected character vector and wrap it in ns(). The series of go_to_*() addins help you go to common files used in developing a {golem} application.

insert_ns() go_to_start() go_to_dev() go_to_deploy() go_to_run_dev() go_to_app_ui() go_to_app_server() go_to_run_app()

golem addins

JavaScript interaction functions

activate_js is used in your UI to insert directly the JavaScript functions contained in golem. These functions can be called from the server with invoke_js. invoke_js can also be used to launch any JS function created inside a Shiny JavaScript handler.

activate_js() invoke_js()

Interact with JavaScript built-in Functions

Options

Set and get a series of options to be used with golem. These options are found inside the golem-config.yml file, found in most cases inside the inst folder.

get_golem_wd() get_golem_name() get_golem_version() set_golem_wd() set_golem_name() set_golem_version() set_golem_options()

golem options

use_recommended_deps adds shiny, DT, attempt, glue, golem, htmltools to dependencies use_recommended_tests adds a test folder and copy the golem tests install_dev_deps install all packages needed for golem developpement

use_recommended_deps() use_recommended_tests()

Add recommended elements

install_dev_deps()

Install golem dev dependencies

Misc

add_module()

Create a module

amend_golem_config()

Amend golem config file

create_golem()

Create a package for a Shiny App using golem

add_resource_path()

Add resource path

browser_button()

Insert an hidden browser button

bundle_resources()

Automatically serve golem external resources

detach_all_attached()

Detach all attached package

document_and_reload()

Document and reload your package

fill_desc()

Fill your description

make_dev()

Make a function dependent to dev mode

with_golem_options()

Add Golem options to a Shiny App

maintenance_page()

maintenance_page