Skip to content

Commit

Permalink
chore: might as well inline that
Browse files Browse the repository at this point in the history
  • Loading branch information
juliusmarminge committed Sep 16, 2022
1 parent 28cc570 commit 46642f9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
3 changes: 0 additions & 3 deletions www/public/makeScrollableCodeFocusable.js

This file was deleted.

7 changes: 6 additions & 1 deletion www/src/components/headCommon.astro
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,12 @@
/>

<!-- Scrollable a11y code helper -->
<script src="/makeScrollableCodeFocusable.js" is:inline></script>
<script is:inline>
const preTags = document.querySelectorAll("pre");
Array.from(preTags).forEach((element) => {
element.setAttribute("tabindex", "0");
});
</script>

<!-- This is intentionally inlined to avoid FOUC -->
<script is:inline>
Expand Down

0 comments on commit 46642f9

Please sign in to comment.