MCPcopy Create free account
hub / github.com/github/docs / filterHidden

Function filterHidden

middleware/contextualizers/generic-toc.js:87–89  ·  view source on GitHub ↗
(child)

Source from the content-addressed store, hash-verified

85async function getTocItems(node, context, opts) {
86 // Cleaner than trying to be too terse inside the `.filter()` inline callback.
87 function filterHidden(child) {
88 return opts.includeHidden || !child.page.hidden
89 }
90
91 return await Promise.all(
92 node.childPages.filter(filterHidden).map(async (child) => {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected