Skip to contents

When called in an Rmd document this function generates child document containing an expandable session info box.


child_session_info(pkgs = c("loaded", "attached", "installed")[1])



Which packages to show. It may be:

  • NULL or "loaded": show all loaded packages,

  • "attached": show all attached packages,

  • "installed": show all installed packages,

  • a character vector of package names. Their (hard) dependencies are also shown by default, see the dependencies argument.


Call this function on a separate line using inline code {r, eval = FALSE, echo = TRUE}r child_session_info().


In CSS Use the .session class to target the whole expandable box. Use summary.session-header to target the box header. Use .session-details to target the content of the box.