Skip to content

Instantly share code, notes, and snippets.

@balupton
Last active December 9, 2023 06:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save balupton/9d486bb71c3fbb9ff66c14e2887ae307 to your computer and use it in GitHub Desktop.
Save balupton/9d486bb71c3fbb9ff66c14e2887ae307 to your computer and use it in GitHub Desktop.
Load Inter Font on Every Webpage
<link rel="preconnect" href="https://rsms.me/" />
<link rel="stylesheet" href="https://rsms.me/inter/inter.css" />
<style>
:root,
html,
body
article,
p,
h1,
h2,
h3,
h4,
h5,
h6 {
-webkit-font-smoothing: antialiased;
font-family: Inter, Comic Sans MS !important;
}
@supports (font-variation-settings: normal) {
:root,
html,
body
article,
p,
h1,
h2,
h3,
h4,
h5,
h6 {
font-family: InterVariable, Comic Sans MS !important;
}
}
</style>
! Title: Inter Font
! Description: Use the Inter font on all body content.
! Version: 0.1.2
! Expires: 1 minute (update frequency)
! Homepage: https://gist.github.com/balupton/9d486bb71c3fbb9ff66c14e2887ae307
! License: https://unlicense.org
*#%#(async function() { document.head.innerHTML += `<link rel="preconnect" href="https://rsms.me/" /> <link rel="stylesheet" href="https://rsms.me/inter/inter.css" /> <style>:root, html, body article, p, h1, h2, h3, h4, h5, h6 { -webkit-font-smoothing: antialiased; font-family: Inter, Comic Sans MS !important; } @supports (font-variation-settings: normal) { :root, html, body article, p, h1, h2, h3, h4, h5, h6 { font-family: InterVariable, Comic Sans MS !important; } }</style>` })()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment