You'd have to update the input yourself when the app initializes based on the URL. You would use the session$clientData$url_search
variable to get the query parameters. Here's an example, you can easily expand this into your needs
library(shiny)
shinyApp(
ui = fluidPage(
textInput("text", "Text", "")
),
server = function(input, output, session) {
observe({
query <- parseQueryString(session$clientData$url_search)
if (!is.null(query[['text']])) {
updateTextInput(session, "text", value = query[['text']])
}
})
}
)
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…