How to open arbitrary PDF in PDF.js viewer?

rstudioserver
bookdown

#1

On my browser'd rstudio server getOption("viewer")("path/to/pdf") opens the pdf in a separate browser window, while knitting to PDF opens an Rstudio Server child frame loading the PDF.js viewer. How can I open an arbitrary PDF using the PDF.js viewer? FWIW I'm using bookdown and pdfs generated under the build pane open in a separate browser tab, so not same experience as using knit button which opens them in PDF.js.

> devtools::session_info()
Session info ----------------------------------------------------------------------------------------------------------
 setting  value                       
 version  R version 3.4.4 (2018-03-15)
 system   x86_64, linux-gnu           
 ui       RStudio (1.1.419)           
 language (EN)                        
 collate  en_US.UTF-8                 
 tz       Etc/UTC