Code Monkey home page Code Monkey logo

Comments (5)

jakubsob avatar jakubsob commented on June 6, 2024 1

R CMD check --as-cran reports:

  • 1 warning, mostly Undocumented arguments in documentation object {Component} and Documented arguments not in \usage in documentation object {Component}
  • 3 notes:
    • package size exceeds allowed 5Mb
      sub-directories of 1Mb or more:
      doc   4.9Mb
      www   4.7Mb
      
    • Unexported object imported by a ':::' call: ‘shiny:::resolve’
    • Multiple: \examples lines wider than 100 characters

from shiny.fluent.

jakubsob avatar jakubsob commented on June 6, 2024

When components are generated using shiny.fluent:::component factory the ... argument is not documented which results in e.g. Undocumented arguments in documentation object 'Toggle' ‘...’. It can be resolved using e.g.

# components.R

component <- function(name) {
  function(...) shiny.react::reactElement(
    module = "@fluentui/react", name = name,
    props = shiny.react::asProps(...),
    deps = shinyFluentDependency()
  )
}

#' Ellipsis documentation template
#' @name doc
#' @param ... Props to pass to \code{shiny.react::reactElement}. See allowed props listed below
NULL

#' @rdname Toggle
#' @inheritParams doc
#' @export
Toggle <- component("Toggle")

But then it prepends ellipsis to the list of arguments of every component

Screenshot 2021-11-19 at 16 38 58

This is in line with actual usage of components as every prop needs to be passed as a named argument using ellipsis, but on the other hand documentation is actually "duplicated" as each prop is contained in ellipsis and it may be confusing.

This "See allowed props listed below" comment may do the job IMO, but do you know any other way how to combine those arguments together in docs? @kamilzyla

Similar thing could be applied to create documentation for {Component}.shinyInput and update{Component}.shinyInput (session, value, inputId) arguments. It would get rid of a huge portion of R CMD check notes.

from shiny.fluent.

corinabioinformatic avatar corinabioinformatic commented on June 6, 2024

Is it any update about the CRAN submission? I tried to install the package for testing purposes from CRAN and it is yet not available (shiny.react it is).

Many thanks,

Corina

from shiny.fluent.

jakubsob avatar jakubsob commented on June 6, 2024

Hi @corinabioinformatic,

submitting the package to CRAN is still in progress, but you can always install the package from GitHub using:

remotes::install_github("Appsilon/shiny.react")
remotes::install_github("Appsilon/shiny.fluent")

from shiny.fluent.

jakubsob avatar jakubsob commented on June 6, 2024

To close this issue those must be closed first:

from shiny.fluent.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.