Skip to content

Modernize shinymaterial package for 2025#136

Open
ericrayanderson wants to merge 2 commits intomasterfrom
claude/modernize-package-2025-EwWlw
Open

Modernize shinymaterial package for 2025#136
ericrayanderson wants to merge 2 commits intomasterfrom
claude/modernize-package-2025-EwWlw

Conversation

@ericrayanderson
Copy link
Owner

  • Update DESCRIPTION with modern dependencies:

    • shiny >= 1.7.0 (was >= 0.7.0)
    • Add rlang (>= 1.0.0) and cli for modern error handling
    • Add testthat (>= 3.0.0) to Suggests
    • Update RoxygenNote to 7.3.2 with markdown support
    • Add BugReports URL
  • Security improvements:

    • Replace eval() with Function() constructor in JS handler
    • Add try/catch error handling for safer code execution
  • Modernize error handling:

    • Replace message("ERROR: ...") with cli::cli_abort()
    • Use structured error messages with cli formatting
  • Update JavaScript to ES6+ patterns:

    • Replace $(document).ready() with DOMContentLoaded
    • Use ES6 class syntax for Shiny.InputBinding
    • Add 'use strict' and JSDoc comments
    • Use const/let instead of var
    • Use arrow functions where appropriate
  • Remove deprecated code:

    • Remove dir_recursion() utility (replaced with dir.create recursive)
    • Use built-in dir.create(..., recursive = TRUE)
  • Add CI/CD infrastructure:

    • Add GitHub Actions R-CMD-check workflow
    • Add GitHub Actions test-coverage workflow
    • Add testthat testing infrastructure with initial tests
  • Update .Rbuildignore for new files

  • Update NAMESPACE with cli and rlang imports

- Update DESCRIPTION with modern dependencies:
  - shiny >= 1.7.0 (was >= 0.7.0)
  - Add rlang (>= 1.0.0) and cli for modern error handling
  - Add testthat (>= 3.0.0) to Suggests
  - Update RoxygenNote to 7.3.2 with markdown support
  - Add BugReports URL

- Security improvements:
  - Replace eval() with Function() constructor in JS handler
  - Add try/catch error handling for safer code execution

- Modernize error handling:
  - Replace message("ERROR: ...") with cli::cli_abort()
  - Use structured error messages with cli formatting

- Update JavaScript to ES6+ patterns:
  - Replace $(document).ready() with DOMContentLoaded
  - Use ES6 class syntax for Shiny.InputBinding
  - Add 'use strict' and JSDoc comments
  - Use const/let instead of var
  - Use arrow functions where appropriate

- Remove deprecated code:
  - Remove dir_recursion() utility (replaced with dir.create recursive)
  - Use built-in dir.create(..., recursive = TRUE)

- Add CI/CD infrastructure:
  - Add GitHub Actions R-CMD-check workflow
  - Add GitHub Actions test-coverage workflow
  - Add testthat testing infrastructure with initial tests

- Update .Rbuildignore for new files
- Update NAMESPACE with cli and rlang imports
Remove extra 'multiple' parameter from Rd file that doesn't exist
in the function signature.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants