shinyreprex 0.3.0
CRAN release: 2026-09-17
New features:
-
reprex_lockfilecaptures the package versions, sources and R version needed to reproduce one or more reactives as anrenvlockfile, withreprex_packagesexposing the detected packages so they can be offered for selection. Packages are detected from every branch of aniforswitch, so the set may be a superset of thelibrary()calls in the reproduced script -
register_reactivesrecords reactives against the Shiny session, soreprex_lockfileandreprex_packagescan be called without arguments and still cover reactives owned by separate modules
Bug fixes:
- Correctly reproduce unbraced
if/elsebranches. Previously a branch that was a single expression rather than a{block had its function call stripped, producing a script containing only the call’s arguments, and any package used solely in that branch went undetected - Return an empty script for an
ifwithout anelsewhose condition is not met, rather than erroring withsubscript out of bounds - Select the correct branch when an
ifcondition evaluates to a truthy value other thanTRUE, such as a non-zero number. Previously the condition itself was reproduced in place of theifbranch - Functions with 0 arguments are now correctly treated as functions rather than reactive objects
Other updates:
- Added
clias a dependency, used for error and warning messages - Added
renvas a dependency, used for producing the lockfile for packages used by reactives