Skip to content

Commit 27e3f9e

Browse files
stefanvjarrodmillman
authored andcommitted
Render literals in shortcuts
1 parent 6d0a3ea commit 27e3f9e

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

assets/js/shortcuts.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,8 +110,7 @@ function setupShortcuts(shortcutDepth = 2) {
110110
if (shortcutsTarget) {
111111
const classElements = Array.from(document.querySelectorAll(classes));
112112
classElements.map((el) => {
113-
// Get title but remove anchor character #
114-
const title = el.textContent.replace(/#$/, "");
113+
const title = el.innerHTML;
115114
const elId = el.id;
116115
// Gets the element type (e.g. h2, h3)
117116
const elType = el.tagName;

0 commit comments

Comments
 (0)