https://github.com/bmoretz/shiny.gentelella
A R/Shiny adaptation of the gentelella bootstrap4 theme.
https://github.com/bmoretz/shiny.gentelella
Last synced: 4 months ago
JSON representation
A R/Shiny adaptation of the gentelella bootstrap4 theme.
- Host: GitHub
- URL: https://github.com/bmoretz/shiny.gentelella
- Owner: bmoretz
- License: mit
- Created: 2021-10-23T22:21:31.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-01-16T22:24:40.000Z (about 3 years ago)
- Last Synced: 2024-08-13T07:03:22.517Z (8 months ago)
- Language: JavaScript
- Size: 433 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.Rmd
- License: LICENSE
Awesome Lists containing this project
- jimsghstars - bmoretz/shiny.gentelella - A R/Shiny adaptation of the gentelella bootstrap4 theme. (JavaScript)
README
---
output: github_document
---```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```# shiny.gentelella
[](https://github.com/bmoretz/shiny.gentelella/actions)
[](https://lifecycle.r-lib.org/articles/stages.html#experimental)
[](https://codecov.io/gh/bmoretz/shiny.gentelella)The goal of shiny.gentelella is to provide a simple, object-oriented application framework styled using the open-source bootstrap4 theme, gentelella.
## Installation
You can install the development version of shiny.gentelella like so:
``` r
remotes::install_github("bmoretz/shiny.gentelella")
```## Example
This is a simple example that shows you how to setup a single page dashboard:
```{r example}
library(shiny.gentelella)ExampleDashboard <- R6::R6Class(
classname = "ExampleDashboard",
inherit = Dashboard,
public = list(#' @field meta page attributes
#' and configuration wrapper.
meta = list(
title = "Example Dashbaord",
nav_definition = system.file("example",
"navigation.yml",
package = "shiny.gentelella")
),#' @description
#' Create a new UI Page object.
#' @return A new `ExampleDashboard` object.
initialize = function() {
super$initialize()
},#' @description user-interface wrapper.
ui = function() {
self$layout()
},#' @description server-side wrapper.
#' @param input form input
#' @param output render output
#' @param session page session
server = function(input, output, session) {private$set_logging()
logger::log_trace("processing server events")
}
),
private = list()
)example <- ExampleDashboard$new()
# Run the application
app <- shinyApp(ui = example$ui(),
server = example$server)# runApp(app, port = 8080)
```
