How r-causal/causal_inference_r_workshop works
Main components
• Workshop Content: This comprises the slides (both raw Quarto/HTML files and compiled PDFs) and exercise files (QMD documents). These represent the educational content that is delivered via a workshop website.
• Build & Configuration: The Quarto configuration files (e.g., _quarto.yml, README.qmd, README.Rmd) and the R project file (causal_inference_r_workshop.Rproj) provide the build environment. They specify how the documents are rendered and packaged.
• Extensions & Customizations: The _extensions directory contains additional extensions (e.g., related to styling, extra functionalities like the “kakashi” extension) which the Quarto build process uses. This also includes specialized SCSS files and configuration files (like _extension.yml) for customizing the output.
• Package-Based Installation: The repository is paired with an R package (causalworkshop) that facilitates the local installation of course materials, emphasizing how the materials are deployed both locally and in a cloud environment.
• Assets & Dependencies: The project makes heavy use of external libraries (e.g., reveal.js libraries, Quarto HTML assets, style libraries) that are used to generate interactive slides and web pages.
Relationships and interactions between components
• Source Documents → Renderer: The exercise and slide documents (QMD files) are rendered using Quarto with configurations defined in _quarto.yml and the R project settings.
• Extensions/CSS → Build Output: Custom extensions placed under _extensions contribute additional styles and behaviors (e.g., via sass/scss files) to the final rendered slides and HTML pages.
• Package Integration: The causalworkshop R package acts as an external service for installing dependencies and materials. It downloads and configures the project locally in the user's environment.
• Assets Integration: Static assets (images, CSS, JavaScript libraries) included in the slides folders (both raw and published pdf directories) are bundled with the final website.
Architectural patterns and design principles
• Static Site Generation: The project follows a static site generation approach where all content is pre-rendered into HTML/PDF formats using Quarto.
• Separation of Concerns: There is a clear separation between content (slides and exercises), build configuration (Quarto config, R project), and customization (extensions, theme files). This aligns well with modular design principles.
• Declarative Build: The system uses declarative documents (in .qmd files) that are processed by Quarto. This simplifies versioning, maintenance, and reproducibility of the teaching materials.
• Extensibility: With the _extensions directory and external package integration, the system is set up to be extended in the future (e.g., for additional themes, content types or interactive elements).
Relevant technologies
• R and RStudio: The project is an R project (with causal_inference_r_workshop.Rproj) relying on R packages.
• Quarto: Used for document rendering, compiling QMD files to HTML and PDF slides.
• Reveal.js: Provides the interactive, slide-based presentation functionality (visible in the many reveal.js library files).
• CSS/JavaScript Libraries: Various assets supporting styling and interactivity.
• Git and GitHub: Version control (as seen from the .gitignore and repository structure).