MCPcopy Create free account
hub / github.com/Boris-code/feapder / getAllPaths

Function getAllPaths

docs/lib/docsify/lib/plugins/search.js:29–47  ·  view source on GitHub ↗
(router)

Source from the content-addressed store, hash-verified

27 }
28
29 function getAllPaths(router) {
30 var paths = [];
31
32 Docsify.dom.findAll('.sidebar-nav a:not(.section-link):not([data-nosearch])').forEach(function (node) {
33 var href = node.href;
34 var originHref = node.getAttribute('href');
35 var path = router.parse(href).path;
36
37 if (
38 path &&
39 paths.indexOf(path) === -1 &&
40 !Docsify.util.isAbsolutePath(originHref)
41 ) {
42 paths.push(path);
43 }
44 });
45
46 return paths
47 }
48
49 function saveData(maxAge, expireKey, indexKey) {
50 localStorage.setItem(expireKey, Date.now() + maxAge);

Callers 1

initFunction · 0.85

Calls 1

parseMethod · 0.45

Tested by

no test coverage detected