fix comment
This commit is contained in:
parent
64b8fd9584
commit
be3f68ed06
2 changed files with 1 additions and 1 deletions
|
|
@ -10,6 +10,7 @@ type Props = {
|
|||
|
||||
const { headings, githubEditUrl } = Astro.props as Props;
|
||||
let currentPage = Astro.url.pathname;
|
||||
// remove slash before #
|
||||
currentPage = currentPage.endsWith('/') ? currentPage.slice(0, -1) : currentPage;
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ const TableOfContents: FunctionalComponent<{ headings: MarkdownHeading[]; curren
|
|||
headings = [],
|
||||
currentPage,
|
||||
}) => {
|
||||
// remove slash before #
|
||||
const toc = useRef<any>();
|
||||
const onThisPageID = 'on-this-page-heading';
|
||||
const itemOffsets = useRef<ItemOffsets[]>([]);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue