{"id":13399311,"url":"https://github.com/juba/rmdformats","last_synced_at":"2025-04-14T23:27:54.881Z","repository":{"id":18425633,"uuid":"21608027","full_name":"juba/rmdformats","owner":"juba","description":"HTML output formats for RMarkdown documents","archived":false,"fork":false,"pushed_at":"2025-04-10T08:58:24.000Z","size":16366,"stargazers_count":725,"open_issues_count":1,"forks_count":141,"subscribers_count":24,"default_branch":"master","last_synced_at":"2025-04-10T09:47:15.243Z","etag":null,"topics":["cran","docco","html","html-theme","material","r","rmarkdown","rstudio"],"latest_commit_sha":null,"homepage":"","language":"CSS","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/juba.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2014-07-08T10:05:49.000Z","updated_at":"2025-04-10T08:54:50.000Z","dependencies_parsed_at":"2024-06-19T03:53:08.880Z","dependency_job_id":"c59fda71-7004-445c-a4fd-666762e9fdfc","html_url":"https://github.com/juba/rmdformats","commit_stats":{"total_commits":506,"total_committers":6,"mean_commits":84.33333333333333,"dds":0.06521739130434778,"last_synced_commit":"024745caa52a9729356e8405445ab56e70e133eb"},"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/juba%2Frmdformats","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/juba%2Frmdformats/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/juba%2Frmdformats/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/juba%2Frmdformats/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/juba","download_url":"https://codeload.github.com/juba/rmdformats/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248977116,"owners_count":21192526,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cran","docco","html","html-theme","material","r","rmarkdown","rstudio"],"created_at":"2024-07-30T19:00:36.215Z","updated_at":"2025-04-14T23:27:54.857Z","avatar_url":"https://github.com/juba.png","language":"CSS","readme":"# rmdformats\n\n[![CRAN_Status_Badge](https://www.r-pkg.org/badges/version-ago/rmdformats)](https://cran.r-project.org/package=rmdformats)\n![CRAN Downloads](https://cranlogs.r-pkg.org/badges/last-month/rmdformats)\n[![R build status](https://github.com/juba/rmdformats/workflows/R-CMD-check/badge.svg)](https://github.com/juba/rmdformats/actions?query=workflow%3AR-CMD-check)\n\n\n\u003e **Note for quarto users:** these templates are only suitable for RMarkdown documents. I published one quarto custom format called [bookup](https://github.com/juba/bookup-html) which is a porting of the `robobook` template.\n\nThis R package provides ready-to-use HTML output formats and templates for\nRMarkdown documents. The goal is to produce clean documents \"out of the box\",\nwith or without the RStudio IDE.\n\n## Formats gallery\n\nThe package provides several HTML output formats. Click on any image to see an HTML output sample.\n\n### `downcute`\n\nTaken from the [docute](https://github.com/egoist/docute) project theme and its adaptation by [John Coene](https://twitter.com/jdatap). Responsive, with a dynamic table of contents and a dark theme switcher.\n\n[![downcute example](man/figures/downcute.png)](https://juba.github.io/rmdformats/articles/examples/downcute.html)\n\n`downcute chaos` is a variation created by [Zac Garland](https://github.com/zac-garland). It has a slightly different color theme, and defaults to dark mode. To use it, add a `downcute_theme: \"chaos\"` option in your YAML preamble.\n\n[![downcute chaos example](man/figures/downcute_chaos.png)](https://juba.github.io/rmdformats/articles/examples/downcute_chaos.html)\n\n### `robobook`\n\nAdapted from the [bookdown](https://bookdown.org/) theme, with Roboto family fonts. Fully responsive with dynamic table of contents and collapsible navigation.\n\n[![robobook example](man/figures/robobook.png)](https://juba.github.io/rmdformats/articles/examples/robobook.html)\n\n### `material`\n\nFormat taken from the [Material design theme for Bootstrap 3](https://mdbootstrap.com/). Document is split into pages at each `\u003ch1\u003e` header, and the table of contents allows an animated navigation between these pages (you can use the `cards: false` preamble parameter to disable the splitting and display all the cards at once).\n\n[![material example](man/figures/material.png)](https://juba.github.io/rmdformats/articles/examples/material.html)\n\n### `readthedown`\n\nAdapted from the corresponding `readtheorg` theme of the [org-html-themes](https://github.com/fniessen/org-html-themes) project, fully responsive with dynamic table of contents and collapsible navigation.\n\n[![readthedown example](man/figures/readthedown.png)](https://juba.github.io/rmdformats/articles/examples/readthedown.html)\n\n### `html_clean`\n\nSimple and clean template with dynamic table of contents, very similar to the one from the great [knitrBootstrap package](https://github.com/jimhester/knitrBootstrap) by Jim\nHester.\n\n[![html_clean example](man/figures/html_clean.png)](https://juba.github.io/rmdformats/articles/examples/html_clean.html)\n\n### `html_docco`\n\nSimple template, no table of contents. CSS heavily inspired from the default one of the [docco](https://ashkenas.com/docco/) project.\n\n[![html_docco example](man/figures/html_docco.png)](https://juba.github.io/rmdformats/articles/examples/html_docco.html)\n\n### `lockdown`\n\n`lockdown` is an exact copy of the default RMarkdown `html_document` template, with an added functionality : each time you click on a link to get out, you'll see a friendly reminder to wash your hands and wear a mask. Yes, it is a (bad) attempt at a (bad) joke, sorry !\n\n[![lockdown example](man/figures/lockdown.png)](https://juba.github.io/rmdformats/articles/examples/lockdown.html)\n\n## Features and helpers\n\n### Features matrix\n\n\u003ctable\u003e\n\u003cthead\u003e\n    \u003ctr\u003e\n    \u003cth\u003e\u003c/th\u003e\n    \u003cth\u003eResponsive\u003c/th\u003e\n    \u003cth\u003eDynamic TOC\u003c/th\u003e\n    \u003cth\u003eDark mode\u003c/th\u003e\n    \u003cth\u003eThumbnails / Lightbox\u003c/th\u003e\n    \u003cth\u003eCode folding\u003c/th\u003e\n    \u003cth\u003eTabsets\u003c/th\u003e\n    \u003cth\u003eBad joke\u003c/th\u003e\n    \u003c/tr\u003e\n\u003c/thead\u003e\n\u003ctbody\u003e\n\u003ctr\u003e\n\u003ctd\u003e\u003cstrong\u003ehtml_docco\u003c/strong\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\u003cstrong\u003ehtml_clean\u003c/strong\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\u003cstrong\u003ereadthedown\u003c/strong\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\u003cstrong\u003ematerial\u003c/strong\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\u003cstrong\u003erobobook\u003c/strong\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\u003cstrong\u003edowncute\u003c/strong\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\u003cstrong\u003elockdown\u003c/strong\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003ex\u003c/td\u003e\n\u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n\n### Helpers\n\nThe package also provides RStudio document\ntemplates to easily generate an empty and ready to use rmarkdown file with\nseveral configuration directives.\n\nIt also provides the `pilltabs()` helper function, which allows to display a crosstab dynamically. See [one of the output samples](https://juba.github.io/rmdformats/articles/examples/robobook.html#table) for a live example.\n\n## Installation\n\nYou can install the latest stable release from CRAN :\n\n```r\ninstall.packages(\"rmdformats\")\n```\n\nOr the latest development snapshot from GitHub :\n\n```r\ninstall.packages(remotes)  # if necessary\nremotes::install_github(\"juba/rmdformats\")\n```\n\n## Creating a new document\n\nJust create a new `Rmd` file and add the following in your YAML preamble :\n\n```yaml\n---\noutput: rmdformats::\u003ctemplate name\u003e\n---\n```\n\nWithin RStudio , you can also choose `File` \u003e `New File...` \u003e `R Markdown...`, then select `From Template`. You should then be able to create a new document from one of the package templates.\n\n## Options\n\nDepending on the features provided by the template, you can add the following options to your YAML preamble. Look at the template function help page for a valid list :\n\n- `fig_width` : figures width, in inches\n- `fig_height` : figures height, in inches\n- `fig_caption` : toggle figure caption rendering\n- `highlight` : syntax highlighting\n- `thumbnails` : if TRUE, display content images as thumbnails\n- `lightbox` : if TRUE, add lightbox effect to content images\n- `gallery` : if TRUE, add navigation between images when displayed in lightbox\n- `use_bookdown` : if TRUE, will use `bookdown` instead of `rmarkdown` for HTML rendering, thus providing section numbering and [cross references](https://bookdown.org/yihui/bookdown/cross-references.html).\n- `embed_fonts` : if `TRUE` (default), use local files for fonts used in the template instead of links to Google Web fonts. This leads to bigger files but ensures that the fonts are available\n- additional aguments are passed to the base `html_document` RMarkdown template\n\nExample preamble :\n\n```yaml\n---\ntitle: \"My document\"\ndate: \"`r Sys.Date()`\"\nauthor: John Doe\noutput:\n  rmdformats::downcute:\n    self_contained: true\n    thumbnails: true\n    lightbox: true\n    gallery: false\n    highlight: tango\n---\n```\n\n## Credits\n\n- [Magnific popup](https://dimsemenov.com/plugins/magnific-popup/) lightbox plugin\n- The CSS for the `html_docco` format is heavily inspired from the default one of the [docco](https://ashkenas.com/docco/) project.\n- The CSS and JavaScript for `readthedown` is adapted from the corresponding `readtheorg` theme of the [org-html-themes](https://github.com/fniessen/org-html-themes) project, which is itself inspired by the [Read the docs](https://readthedocs.org/) [Sphinx](http://sphinx-doc.org/) theme.\n- The CSS and JavaScript for `material` has been taken from the [Material design theme for Bootstrap 3](https://github.com/FezVrasta/bootstrap-material-design) project and its [presentation page](https://fezvrasta.github.io/bootstrap-material-design/).\n- The CSS for `robobook` is directly derived from the [bookdown](https://bookdown.org/) project template.\n- The CSS for `downcute` is directly derived from the default theme of the [docute](https://github.com/egoist/docute) project and its adaptation by [John Coene](https://twitter.com/jdatap) for some of its [projects documentation](https://packer.john-coene.com/).\n- The `downcute chaos` theme has been created by [Zac Garland](https://github.com/zac-garland).\n- JavaScript and HTML code for code folding and tabbed sections are taken from the RStudio's default `rmarkdown` HTML template.\n- The `html_clean` styling and features are very similar to the ones from the \n[knitrBootstrap package](https://github.com/jimhester/knitrBootstrap) by Jim\nHester.\n","funding_links":[],"categories":["HTML","CSS","Rmarkdown Templates"],"sub_categories":["HTML Page"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjuba%2Frmdformats","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjuba%2Frmdformats","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjuba%2Frmdformats/lists"}