I have a bookdown rmd looking like...
Further introductory materials are offered when the package is loaded:
```{r dt-startup, echo=-1, message=TRUE, verbose=TRUE, hide=FALSE}
if ("data.table" %in% .packages()) detach("package:data.table")
library(data.table)
```
My intention was to show the reader the package's startup messages. However, they don't print. Is there some other chunk option to use here?
As you can see, I just threw several maybe-relevant chunk options at it to no good result. I'm not terribly familiar with management of output streams, so that's as far as I knew to go. I also tried calling directly with data.table:::.onAttach()
, but no dice.
I'm not sure what else would be relevant here, but ...
- Currently the package has not been loaded before this chunk. I just added the first line for robustness in case I rearrange the document.
- My before_chapter_script contains nothing but
knitr::opts_chunk$set(comment="#")
. - My knit header value is
bookdown::render_book
and the output isbookdown::html_book
.