MCPcopy Index your code
hub / github.com/hoothin/UserScripts / getDepth

Function getDepth

DownloadAllContent/DownloadAllContent.user.js:1702–1709  ·  view source on GitHub ↗
(dom)

Source from the content-addressed store, hash-verified

1700 }
1701
1702 function getDepth(dom){
1703 var pa=dom,i=0;
1704 while(pa.parentNode){
1705 pa=pa.parentNode;
1706 i++;
1707 }
1708 return i;
1709 }
1710
1711 async function sleep(time) {
1712 await new Promise((resolve) => {

Callers 1

getContentByLargestFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected