shinyobjects icon indicating copy to clipboard operation
shinyobjects copied to clipboard

Load library(shiny) for user

Open rjake opened this issue 4 years ago • 0 comments

Was using this code in https://github.com/rjake/shinyobjects/pull/41/commits/71aca771cfac04b6c2af423b8693adeb4bae3550 but it threw a warning in devtools::check()

# add library(shiny) if not included
if (!any(grepl("library\\(shiny\\)", final_code))) {
  final_code <- 
    append(
      final_code, 
      expression(
        if (requireNamespace("shiny", quietly = TRUE)) require(shiny)
      ),
      after = 0
    )
}
checking dependencies in R code ... NOTE
  'library' or 'require' call to 'shiny' in package code.
    Please use :: or requireNamespace() instead.
    See section 'Suggested packages' in the 'Writing R Extensions' manual.

rjake avatar Jul 06 '20 03:07 rjake