% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/builder.R
\name{launch_builder}
\alias{launch_builder}
\title{Launch the surveyframe visual survey builder}
\usage{
launch_builder(open = TRUE)
}
\arguments{
\item{open}{Logical. When \code{TRUE} (the default), the builder HTML file is
opened in the system's default web browser with \code{\link[utils:browseURL]{utils::browseURL()}}.
Set to \code{FALSE} to return the file path without opening it, which is
useful for automated testing.}
}
\value{
The path to the bundled builder HTML file, invisibly.
}
\description{
Opens the SurveyBuilder, a self-contained HTML application for visual survey
design. The builder runs client-side without an R session or Shiny server.
Save instruments as \code{.sframe} files from the browser and load them into R
with \code{\link[=read_sframe]{read_sframe()}}.
}
\details{
The builder includes a three-mode interface.

\describe{
\item{Build}{An item editor with a persistent inspector panel,
drag-to-reorder, undo/redo, and autosave to browser localStorage.}
\item{Preview}{A full live render of the survey showing welcome, body,
and thank-you pages.}
\item{Analyse}{A role-based analysis planner with method-specific
options, planned outputs, reporting references, and decision rules.}
}

The builder includes a pure-JavaScript SHA-256 fallback for browsers or
security policies where \code{crypto.subtle} is unavailable on \verb{file://}
origins. Saved \code{.sframe} files can be loaded and validated with
\code{\link[=read_sframe]{read_sframe()}}.
}
\examples{
# Retrieve the builder path for inspection without opening the browser
path <- launch_builder(open = FALSE)
file.exists(path)
}
\seealso{
\code{\link[=launch_studio]{launch_studio()}}, \code{\link[=read_sframe]{read_sframe()}}, \code{\link[=run_analysis_plan]{run_analysis_plan()}}
}
