Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Golem App Development in Positron #1185

Open
dleopold opened this issue Jan 23, 2025 · 1 comment
Open

Golem App Development in Positron #1185

dleopold opened this issue Jan 23, 2025 · 1 comment

Comments

@dleopold
Copy link

I have found myself needing to manage multiple R versions and decided to give the new IDE from Posit, Positron, a spin. One thing I have not figured out is how to get my golem projects to open in my browser instead of the internal viewer pane. In RStudio, I simply add options(shiny.launch.browser = T) to the project's .Rprofile. I can not seem to get the same behavior in Positron. I am posting here because I can get "vanilla" shiny apps to launch in the browser by modifying the Positron setting, "shiny.previewType": "external". But, this does not affect how my golem projects open. For efficient golem app development in Positron I think it is necessary to be able to use an external browser as the default.

@dleopold
Copy link
Author

dleopold commented Jan 24, 2025

I have a workable solution for now (probably not optimal). I created an app.R file in the project root directory with the following:

options(shiny.autoreload = FALSE)
options(golem.app.prod = FALSE)
devtools::document()
run_app()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant