% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/render_survey.R
\name{render_survey}
\alias{render_survey}
\title{Render a survey from an instrument object}
\usage{
render_survey(
  instrument,
  mode = c("shiny"),
  title = NULL,
  theme = NULL,
  save_responses = c("none", "csv"),
  output_path = NULL,
  on_submit = NULL
)
}
\arguments{
\item{instrument}{An \code{sframe} object.}

\item{mode}{Character. Deployment mode. Currently \code{"shiny"}.}

\item{title}{Character or NULL. Override for the survey title.}

\item{theme}{Character or NULL. Hex colour for the survey theme.}

\item{save_responses}{Character. \code{"none"} (default) or \code{"csv"}.}

\item{output_path}{Character or NULL. CSV path when \code{save_responses = "csv"}.}

\item{on_submit}{Function or NULL. Callback receiving the submitted row.}
}
\value{
A \code{shiny.appobj}.
}
\description{
Launches a Shiny survey with a welcome page, configurable header, all item
types, branching logic, required-field enforcement, progress tracking,
standard and conversational (one-question-at-a-time) display modes, and a
customisable thank-you page. Responses can be persisted to CSV or passed to
a callback.
}
\examples{
\donttest{
render_survey(instr)
render_survey(instr, save_responses = "csv", output_path = "responses.csv")
}
}
\seealso{
\code{\link[=launch_studio]{launch_studio()}}, \code{\link[=read_responses]{read_responses()}}
}
