Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: remove console.log from TableOfContents
Browse files Browse the repository at this point in the history
cheton committed Sep 24, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
1 parent 70a0bbd commit c28dfe7
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion packages/react-docs/components/TableOfContents.js
Original file line number Diff line number Diff line change
@@ -55,7 +55,6 @@ const TableOfContents = (props) => {
if (mainContent) {
// Use the `:scope` pseudo-class to select all direct child heading elements of the main content, excluding h1
const headingSelectors = ['h2', 'h3', 'h4', 'h5', 'h6'].map(h => `:scope>${h}`).join(',');
console.log(headingSelectors);
setNodes(Array.from(mainContent.querySelectorAll(headingSelectors)));
}

0 comments on commit c28dfe7

Please sign in to comment.