Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

read directory in node js

const testFolder = './tests/';
const fs = require('fs');

fs.readdir(testFolder, (err, files) => {
  files.forEach(file => {
    console.log(file);
  });
});
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #read #directory #node #js
ADD COMMENT
Topic
Name
6+8 =