don't let typekit css block rendering
This commit is contained in:
+16
-1
@@ -35,7 +35,22 @@ export default function RootLayout({
|
|||||||
<html lang="no">
|
<html lang="no">
|
||||||
<head>
|
<head>
|
||||||
<link rel="preconnect" href="https://use.typekit.net" crossOrigin="anonymous" />
|
<link rel="preconnect" href="https://use.typekit.net" crossOrigin="anonymous" />
|
||||||
<link rel="stylesheet" href="https://use.typekit.net/spa5smt.css" />
|
<link rel="preconnect" href="https://p.typekit.net" crossOrigin="anonymous" />
|
||||||
|
{/*
|
||||||
|
Load Adobe Fonts without blocking render: the stylesheet is requested
|
||||||
|
with media="print" (fetched but not applied), then the inline script
|
||||||
|
below swaps it to media="all" once it has loaded.
|
||||||
|
*/}
|
||||||
|
<link
|
||||||
|
id="typekit-css"
|
||||||
|
rel="stylesheet"
|
||||||
|
href="https://use.typekit.net/spa5smt.css"
|
||||||
|
media="print"
|
||||||
|
suppressHydrationWarning
|
||||||
|
/>
|
||||||
|
<script>
|
||||||
|
{`(function(){var l=document.getElementById('typekit-css');if(!l)return;function s(){l.media='all'}if(l.sheet){s()}else{l.addEventListener('load',s)}})();`}
|
||||||
|
</script>
|
||||||
{process.env.UMAMI_SCRIPT_URL && process.env.UMAMI_WEBSITE_ID && (
|
{process.env.UMAMI_SCRIPT_URL && process.env.UMAMI_WEBSITE_ID && (
|
||||||
<script
|
<script
|
||||||
defer
|
defer
|
||||||
|
|||||||
Reference in New Issue
Block a user