untitled notebook

node v10.24.1
version: 1.0.0
endpointsharetweet
const processPath = require("dir-roll-up"); const dirNodeGenerator = processPath("."); const interval = setInterval(async () => { /** * Get the next directory... */ const dirNode = await dirNodeGenerator.next(); /** * ..display it.. */ console.log(dirNode.value); /** * ..and end the interval when last directory retrieved (which will be the root) */ if (dirNode.done) { console.log("Finished!"); clearInterval(interval); } }, 300);
Loading…

no comments

    sign in to comment