MCPcopy Create free account
hub / github.com/cortex-js/compute-engine / extractLinks

Function extractLinks

benchmarks/wester/extract.mjs:32–37  ·  view source on GitHub ↗
(html)

Source from the content-addressed store, hash-verified

30}
31
32function extractLinks(html) {
33 const links = [];
34 const pattern = /HREF="(demos\/[^"]+\/Math\.(?:problems|heat|dif|local|match))"/g;
35 for (const match of html.matchAll(pattern)) links.push(match[1]);
36 return [...new Set(links)];
37}
38
39function isTiming(line) {
40 return /^\s*(?:\d+(?:\.\d*)?|\.\d+)\s+Second(?:s)?\s*$/.test(line);

Callers 1

extract.mjsFile · 0.85

Calls 1

matchAllMethod · 0.65

Tested by

no test coverage detected