Function

@google-font

Load a font from Google Fonts by name and use it as the font-family.

Syntax

  • font-family: @google-font("<name>")

The call is replaced by the family name. Quote names that contain spaces; a single word such as @google-font(Lato) needs no quotes. A stylesheet link is added to the page on first use, and the font is embedded when the doodle is exported with export().

Examples

@grid: 4 / 60vmin _1px;
background: #000;
color: #fff;
font-family: @google-font("Alfa Slab One");
font-size: 2em;
@content: @p([A-Z]);

See also