Skip to content

Commit

Permalink
CLDR-17933 site: auto linkify headings
Browse files Browse the repository at this point in the history
- add anchor.js (same as used w/ spec)
- load from CDN
  • Loading branch information
srl295 committed Sep 10, 2024
1 parent be67120 commit b60bf4a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/site/_layouts/page.html
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
</footer>
<!-- workaround for cloudflare content-type issue -->
<script src="/assets/vendor/vue.global.prod.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/anchor-js/5.0.0/anchor.min.js" integrity="sha512-byAcNWVEzFfu+tZItctr+WIMUJvpzT2kokkqcBq+VsrM3OrC5Aj9E2gh+hHpU0XNA3wDmX4sDbV5/nkhvTrj4w==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
<script src="/assets/js/cldrsite.js"></script>
</body>

Expand Down
3 changes: 3 additions & 0 deletions docs/site/assets/js/cldrsite.js
Original file line number Diff line number Diff line change
Expand Up @@ -258,3 +258,6 @@ const app = Vue.createApp(
// });

app.mount("#nav");

// load anchor.js
anchors.add("h1, h2, h3, h4, h5, h6, caption, dfn");

0 comments on commit b60bf4a

Please sign in to comment.