plumber icon indicating copy to clipboard operation
plumber copied to clipboard

Use httpuv staticPaths

Open dernst opened this issue 6 years ago • 1 comments

httpuv somewhat recently added the feature that static files can be served without calling R code. On top of potential performance improvements httpuv also enables HTTP caching directives for static files, so that files don't have to be re-transmitted every time a page is viewed in browser (for example plotly is around 3MB of minified javascript which is.. noticeable).

plumber could be extended with a new slot staticPaths which is a named list specifying which URLs are mapped to local directories (much like @assets does now).

I could probably prepare a pull request if wanted.

dernst avatar Sep 06 '19 12:09 dernst

A PR would be great! Thank you!

Bonus request: Have the ability to retrieve all of the files in the static path for path information for OpenApi.

schloerke avatar Sep 06 '19 17:09 schloerke