Skip to content

Move rmarkdown from Imports to Suggests#497

Merged
cpsievert merged 4 commits intoramnathv:masterfrom
cpsievert:cpsievert/rmarkdown-suggests
Apr 22, 2026
Merged

Move rmarkdown from Imports to Suggests#497
cpsievert merged 4 commits intoramnathv:masterfrom
cpsievert:cpsievert/rmarkdown-suggests

Conversation

@cpsievert
Copy link
Copy Markdown
Collaborator

Summary

  • Moves rmarkdown from Imports to Suggests in DESCRIPTION
  • Guards write_md_for_pandoc() and pandoc_self_contained_html() with a runtime check, so users who never call saveWidget(selfcontained = TRUE) don't need rmarkdown installed
  • Defers the use_raw_attr default (previously evaluated rmarkdown::pandoc_available("2.0") eagerly at function definition) to runtime

Closes #455

Test plan

  • Added tests verifying both pandoc helpers error informatively when rmarkdown is absent
  • Full test suite passes (12/12)
  • R CMD check passes with 0 errors, 0 warnings

🤖 Generated with Claude Code

rmarkdown is only needed for the selfcontained=TRUE path in
saveWidget(). Guard the pandoc helper functions with a runtime
check so users who never need self-contained output don't need
rmarkdown installed.

Closes ramnathv#455

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@cpsievert cpsievert force-pushed the cpsievert/rmarkdown-suggests branch from 897e3ef to 2275b83 Compare April 21, 2026 22:51
cpsievert and others added 2 commits April 21, 2026 18:11
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

This comment was marked as resolved.

Add minimum version constraint (>= 1.0.0) for rlang to ensure
check_installed() is available. Guard test-pandoc.R against missing
rmarkdown with skip_if_not_installed().

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@cpsievert cpsievert merged commit 08ad901 into ramnathv:master Apr 22, 2026
8 checks passed
@cpsievert cpsievert deleted the cpsievert/rmarkdown-suggests branch April 22, 2026 16:54
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.

Move rmarkdown back to Suggests

2 participants