How to use walk

Comprehensive walk code examples:

How to use walk.walk:

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));
}