Skip to content

Commit

Permalink
fix bad script tag
Browse files Browse the repository at this point in the history
  • Loading branch information
colegoldsmith committed Jan 25, 2024
1 parent 59cc249 commit a871751
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/partials/head-scripts.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,8 @@
/>

<script>
var prefersTheme = window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light' var storedTheme =
localStorage.getItem('theme') || prefersTheme if (storedTheme) { document.documentElement.setAttribute('data-theme',
storedTheme) } else { document.documentElement.setAttribute('data-theme', 'light') }
document.documentElement.setAttribute('data-theme', localStorage.getItem('theme') ||
window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light' || 'light')
</script>

<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@docsearch/css@3" />

0 comments on commit a871751

Please sign in to comment.