Support pages in subfolder

Pages that exist in subfolders such as /tutorials/ are now OK, as
long as the add this line to the frontmatter:

prefix: "/"

This ensures that nav elements including top nav, sidebar, breadcrumbs,
all work, and that the appropriate JavaScript loads as intended.
This commit is contained in:
mDuo13
2022-02-16 10:46:28 -08:00
parent e458d6637e
commit a1021441c7
12 changed files with 54 additions and 54 deletions

View File

@@ -3,9 +3,9 @@
<!-- expandable code samples -->
<script src="assets/js/expandcode.js"></script>
<script src="{{currentpage.prefix}}assets/js/expandcode.js"></script>
<!-- multi-code selection tabs -->
<script src="assets/js/multicodetab.js"></script>
<script src="{{currentpage.prefix}}assets/js/multicodetab.js"></script>
<!-- copy code button -->
<script src="https://cdn.jsdelivr.net/npm/clipboard@2.0.8/dist/clipboard.min.js"></script>
<script>