Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save nanasnumber/c367fc49d70ab2b61034db6dc08d29b3 to your computer and use it in GitHub Desktop.
Save nanasnumber/c367fc49d70ab2b61034db6dc08d29b3 to your computer and use it in GitHub Desktop.
Medium Inspired Typography (or just plain old print typography)

Medium Inspired Typography (or just plain old print typography)

Heading Text

font-family: 'Open Sans', sans-serif;
line-height: 1.5;
font-weight: bold;
font-size: 2.5rem;

Body Text

font-family: 'Lora', serif;
line-height: 1.5;
font-size: 1.5rem;

h tags

  • h1 => 2.5rem
  • h2 => 1.5rem
  • h3 => 1.5rem
  • h4 => 1.5rem
  • h5 => 1.5rem
  • h6 => 1.5rem

Adjust the h tag ratio h2 ~ h6 as needed, in the current case from h2 down is using body text size, but differenciate itself as heading using heading font family.


Google Fonts

Place the font link within head tag

<link href="https://fonts.googleapis.com/css?family=Open+Sans:300,400,700" rel="stylesheet">
<link href="https://fonts.googleapis.com/css?family=Lora:400,400i,700,700i" rel="stylesheet">
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment