Swap to use IdAttributePlugin instead of markdown-it-anchor

This commit is contained in:
Zach Leatherman
2024-07-16 15:45:08 -05:00
parent 49610beab3
commit 1c3c777a1e
5 changed files with 74 additions and 28 deletions

View File

@@ -32,6 +32,8 @@
<style>{% getBundle "css" %}</style>
{#- Renders the CSS bundle using a separate file, if you can't set CSP directive style-src: 'unsafe-inline' #}
{#- <link rel="stylesheet" href="{% getBundleFileUrl "css" %}"> #}
{%- js %}{% include "public/js/heading-anchors.js" %}{% endjs %}
</head>
<body>
<a href="#skip" class="visually-hidden">Skip to main content</a>
@@ -51,7 +53,9 @@
</header>
<main id="skip">
{{ content | safe }}
<heading-anchors>
{{ content | safe }}
</heading-anchors>
</main>
<footer>
@@ -59,5 +63,6 @@
</footer>
<!-- This page `{{ page.url | htmlBaseUrl }}` was built on {% currentBuildDate %} -->
<script type="module" src="{% getBundleFileUrl "js" %}"></script>
</body>
</html>