Skip to content

Commit

Permalink
Fix preloading using suggestion from StackOverlfow
Browse files Browse the repository at this point in the history
@see https://stackoverflow.com/a/46750893

Signed-off-by: Taras Mankovski <taras@frontside.com>
  • Loading branch information
taras committed Nov 2, 2023
1 parent 5a40947 commit 777a869
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions www/html/app.html.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,12 @@ export default function* AppHtml({ title }: Options): Operation<JSX.Element> {
href={yield* useUrl("/")}
hreflang="x-default"
/>
<link rel="preload" as="style" href="/assets/prism-atom-one-dark.css" />
<link rel="preload" as="style" href="https://use.typekit.net/ugs0ewy.css" />
<link href="/assets/prism-atom-one-dark.css" rel="preload" as="style" onload="this.rel='stylesheet'" />
<link href="https://use.typekit.net/ugs0ewy.css" rel="preload" as="style" onload="this.rel='stylesheet'" />
<noscript>
<link rel="stylesheet" href="https://use.typekit.net/ugs0ewy.css" />
<link rel="stylesheet" href="/assets/prism-atom-one-dark.css" />
</noscript>
</head>
<body class="max-w-screen-2xl m-auto">
<header class="header w-full top-0 p-6 sticky tracking-wide z-10">
Expand Down

0 comments on commit 777a869

Please sign in to comment.