prep_input: Prep Input for Shiny App 'editor()'

View source: R/prep_input.R

prep_inputR Documentation

Prep Input for Shiny App editor()

Description

Internal function not intended for users. Basically reconciles saved data, input data from shiny, and reactive values not included in input. This function is used to tell the front end whether there are unsaved changes.

Usage

prep_input(input, yaml_path = NULL, existing_current_data = NULL, WD = "?")

Arguments

input

shiny input variable

yaml_path

relative path to front-matter.yml; default=NULL; preferred way is to provide WD

existing_current_data

optional; reactive 'vals' variable containing certain environmental variables that don't have direct user inputs, but are included in front-matter.yml output. Pass in existing_current_data if you want to preserve reactive values (from being overwritten) that are not found in input or yaml.

WD

working directory

Value

a list that contains saved_data and current_data, allowing to check for unsaved changes


galacticpolymath/GPpub documentation built on April 5, 2025, 6:04 p.m.