This R package showcases how RStudio project templates can be defined and exposed within R packages. See https://rstudio.github.io/rstudio-extensions/rstudio_project_templates.html for more information.
Install this package with:
devtools::install_github("rstudio/ptexamples")