I am using the following code on the server to perform bookmarks.
setBookmarkExclude(c("bookmark1"))
observeEvent(input$bookmark1, {
session$doBookmark()
})
onRestore(function(state) {
if(DEBUG)cat(file=stderr(), paste("getwd:", getwd() ," \n"))
})
Here, the debug message shows that I am working in the current working directory of the app, and not the bookmark folder.
(I tried this without closing the session and using the bookmark from Chrom, while there was another session open within RStudio (Run in Window).
I am running into a problem with the fileInput. The input variable from the bookmark directory (input.rds) stores the plain file name without directory information. Thus, I cannot load the file because I don't know the exact location.
Further info:
I am starting the app with:
shinyApp(ui, server, enableBookmarking = "server")
The ui function starts like this:
ui <- function(request) {
dashboardPage(
where request is never used.
The server function, which contains some of the above code starts like this:
server <- function(input, output, session) {
The whole app is a few thousand lines long, which I would like to spare you from
but can be accessed at: github.com/baj12/scShinyHub
I would assume that since the server is still running in RStudio and thus the result of getwd is explained. But then I don't understand how to use bookmarks and if it is possible to use the server side bookmarks without a commericial server license...
Could you please help me and let me where I might be missing something?
thx in advance.