Skip to content

Commit 962d83d

Browse files
committed
Refresh categories on hash change
Fixes #1139
1 parent 9fcdc72 commit 962d83d

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/project/types/website/listing/website-listing-template.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -516,6 +516,12 @@ export function templateJsScript(
516516
window['quarto-listing-loaded']();
517517
}
518518
});
519+
520+
window.addEventListener('hashchange',() => {
521+
if (window['quarto-listing-loaded']) {
522+
window['quarto-listing-loaded']();
523+
}
524+
})
519525
`;
520526
return jsScript;
521527
}

0 commit comments

Comments
 (0)