MyNixOS website logo
Description

Enterprise Streamlined 'shiny' Application Framework Using 'bs4Dash'.

A framework for building enterprise, scalable and UI-standardized 'shiny' applications. It brings enhanced features such as 'bootstrap' v4 <https://getbootstrap.com/docs/4.0/getting-started/introduction/>, additional and enhanced 'shiny' modules, customizable UI features, as well as an enhanced application file organization paradigm. This update allows developers to harness the ability to build powerful applications and enriches the 'shiny' developers' experience when building and maintaining applications.

CRAN status Downloads Total CircleCI build status codecov

Overview

periscope2 is a scalable and UI-standardized 'shiny' framework including a variety of developer convenience functions with the goal of both streamlining robust application development and assisting in creating a consistent user experience regardless of application or developer.

periscope2 is full of developer-friendly features such as:

  • Predefined but flexible templates for new Shiny applications with a default bs4Dash layout
  • Separation by file of functionality that exists in one of the three shiny scopes: global, server-global, and server-local
  • Generated applications are organized in an easy to follow and maintain folder structure based on files functionality
  • Off-the-shelf and ready to be used modules ('Table Downloader', 'Plot Downloader', 'File Downloader' and 'Reset Application'
  • Different methods and tools to alert users and add useful information about application UI and server operations
  • Application logger with different levels and a UI tool to display and review recorded application logs
  • Application look and feel can be customized easily via 'www/periscope_style.yaml' or more advanced via 'www/css/custom.css'
  • Application can make use of JS power by customizing 'www/js/custom.js'

Create and run sample app for full features demo

periscope2::create_application(name = "demo_app", location = ".", sample_app = T, right_sidebar = T)
shiny::runApp("./demo_app/", launch.browser = T)

Installation

periscope2 is available for installation from CRAN

devtools::install_cran("periscope2")

and latest development version of periscope2 from GitHub as follows:

devtools::install_github('Aggregate-Genius/periscope2')


periscope vs periscope2

periscope is widely regarded and used an enterprise application development aid framework for providing the user with the ability to build a robust shiny applications and dashboards.

periscope is the direct ancestor of periscope2 in which periscope2 took most of its basic philosophy and generated applications structure.

However; as periscope2 is the next generation (iteration) of periscope package, they differ in many aspects as follow:

Underlying frameworks

periscope is dependent on bootstrap 3 supported shiny packages:

While periscope2 is dependent only on bootstrap 4 supported shiny package to bring in more functionality (i.e dashboard functionality, alerts, tool-tips, etc..) and a modernized look and feel:


Generated applications layout

periscope full generated app layouts:

  • Left sidebar
  • Right sidebar
  • Header
  • Body

periscope2 full generated app layouts:

  • Left sidebar
  • Right sidebar
  • Header
  • Footer
  • Body

For periscope2, each part has it own UI R file that can be customized and updated. Each part also has its own dedicated alert panel, including an announcements framework as part of the header.

User can adapt layout for both packages generated apps easily via related functions (refer to r ?periscope and r ?periscope2 for more info)


Generated applications code structure

  • Regardless files contents, both packages generated applications share the same first level folder structure:
  • Differences in the next level of structure are:
    • periscope2 program folder has:
      • a dedicated UI R script for each layout part
      • config - folder for storing application different configuration files
        • Initially contains announcements module configuration file
      • modules - folder for application shiny modules R scripts
    • www folder that contains the application JS, CSS and theme customization files
      • Although generated applications by both frameworks will have the same folder structure, periscope2 generated applications will have two additional files css/custom.css and js/custom.js to hold custom application JS and CSS code
        • Both of these files are already linked into the generated app and ready to be used

Periscope2 Modules

  • Both packages share the following modules:
    • downloadable file
    • downloadable plot
    • downloadable table
  • However, periscope2 has more modules (more to come with each new version) as Announcements module
  • The following modules behave differently between the two packages:
    • Reset Application
    • Logger

NOTE: Check package documentation and vignettes for module details


Periscope2 RStudio Add-ins

Periscope2 provides multiple RStudio add-ins to help package user to configure different generated application aspects visually and correctly. Please refer to the following documentation for each add-in details:

  • vignette("announcement_addin", package = "periscope2")
  • vignette("themeBuilder_addin", package = "periscope2")

Old Shiny module style support

While periscope modules can be called either via the old style (callModule) or new style (moduleServer1), periscope2 only supports the new module style. Check migrating to module server article for more related technical info.


fresh package Styling Support

fresh package is used in both packages to style generated applications different parts via configurations rather than code using the 'www/periscope_style.yaml' file.

While periscope uses shiny dashboard variables for styling in code and via the 'www/periscope_style.yaml' configuration file, periscope2 uses bs4dash related variables . The file key names use related shiny dashboard or bs4dash variables for user friendly styling in both packages.


Examples

These are included to get you started. You can either start with an empty application or an application that includes samples of the components that you can use within your application. There is extensive package documentation and full Vignettes are also available to help you with all the options.


Empty application

periscope2::create_application('emptyapp', location = ".")
shiny::runApp('emptyapp', launch.browser = T)

Sample application - no right sidebar

periscope2::create_application("sampleapp1", location = ".", sample_app = TRUE)
shiny::runApp('sampleapp1', launch.browser = T)

Sample application - including a right sidebar

periscope2::create_application("sampleapp2", location = ".", sample_app = TRUE, right_sidebar = TRUE)
shiny::runApp('sampleapp2', launch.browser = T)

Metadata

Version

0.2.3

License

Unknown

Platforms (75)

    Darwin
    FreeBSD
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    WASI
    Windows
Show all
  • aarch64-darwin
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64_be-none
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-darwin
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-darwin
  • i686-freebsd
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • vc4-none
  • wasm32-wasi
  • wasm64-wasi
  • x86_64-cygwin
  • x86_64-darwin
  • x86_64-freebsd
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-windows