Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
:::
. I guess it needs a workaround for CRAN to accept it.Changes
Implements automatic reloading from #339.
With
shiny.autoreload
working I don't think we need to modifyshiny.autoreload.pattern
. Runningrhino::build_js(watch = TRUE)
andrhino::build_sass(watch = TRUE)
outputs minified.js
and.css
files respectively. Shiny by default tracks.js
and.css
changes, so it will reload when either JS or CSS is built.How to test
pak::pak("TymekDev/rhino@autoreload")
rhino::init()
options(shiny.autoreload = TRUE)
shiny::runApp()
(rhino::app
won't work!)This will work in new and old apps alike. The only thing that changed is the main module is not passed directly. Instead, an environment where it was loaded with
box::use
is passed. This allowsbox::reload
to work.