No Sheng Sheng default With fonts


Sheng is a Sass and CSS library for laying out type on the Web, which is opinionated about sizing and spacing, but leaves fonts and colours up to you.

It is named after Bì Shēng, the inventor of movable type.

It is intended to be a JS-free alternative to typography.js, but is not a pixel-perfect drop-in, instead taking a few different opinions in some places.


You can either use Sheng as a Sass library, or include its CSS directly if you're not using Sass. Then, you can add further rules to add your fonts, colours, and site-specific customisations.


The Sass file provides a sheng() mixin, which applies Sheng's styles. It takes the following parameters (all are optional):

You can additionally extend or override styles using Sheng's placeholder selectors, and Sheng will apply them to the appropriate selectors. They are:

@import "~sheng/sheng.scss";
.content {
  @include sheng();
%sheng-heading {
  font-family: sans-serif;
  font-weight: 900;


The CSS version is always applied to the .type selector. You can override some of Sheng's defaults using CSS Variables:

@import "";
.sheng {
  --body-font-family: Helvetica, sans-serif;

Example content


  1. Ordered list item 1
  2. Ordered list item 2
  3. Ordered list item 100