How to use walk.walk:
GitHub: coveo/search-ui
24 25 26 27 28 29 30 31 32 33 34 35 36
console.log('Generating icon list'); let icons = []; let walker = walk.walk(iconsDir); walker.on('file', (root, fileStats, next) => fileHandler(icons, root, fileStats, next)); walker.on('end', () => endHandler(icons, outputDir, fileName, done)); }
75
124
12
See more examples