Sass compiler package for R
Switch branches/tags
Nothing to show
Clone or download
Latest commit c73867d Oct 17, 2018

README.md

README

sass

Travis build status AppVeyor build status CRAN_Status_Badge

The sass R package is a CSS preprocessor, letting R developers use variables, inheritance, and functions to generate dynamic style sheets.

sass uses the Sass CSS extension language. Sass is stable, powerful, and CSS compatiable. sass is an R wrapper for LibSass, a fast Sass compiler written in C++.

Installation

Install the released version of sass from CRAN:

install.packages("sass")

Install the latest development build from Github:

# install.packages("devtools")
devtools::install_github("rstudio/sass")

Getting Started

The Sass language syntax is similar to CSS, but allows functions and variables, and can do arbitrary computations.

library(sass)

sass("
  $size: 50%;
  foo { margin: $size * .33; }
")
#> /* CSS */
#> foo {
#>   margin: 16.5%;
#> }

For an overview of the major features of Sass such as variables, nesting, and imports check out the official Sass Basics.

Examples