This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# About ------------------------------------------------------------------- | |
# This script file is a guide that I use while I'm setting up a new package or | |
# making changes to existing packages. I started this when I created my first | |
# package, just to keep track of what I was doing because I was initially very | |
# confused. It quickly evolved into a workflow reference that I use continuously | |
# while working on a package. I keep this open in RStudio alongside whichever | |
# package files I'm editing. Though I may be using it in multiple packages at | |
# once, it's saved separately from any particular package or project. This way, | |
# if I need to make an edit then I'm making it once only. The code snippets and |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Dynamic UI: demonstrate destroy() method on observer | |
# This example makes use of a module that dynamically creates pages | |
# Each server part of the module creates an observer that listens to an actionButton | |
# Whenever a page is removed, the observer is destroyed. The UI is removed with | |
# the nav_remove() function. | |
library(shiny) | |
library(bslib) | |
sportsPageUI <- function(id, page_name) { |