Currently, I have a folder containing 50 mp3 files. My goal is to create an object for each file that includes its name and source.
However, the challenge lies in figuring out how to select and retrieve properties from all of the files. Is this even possible? I am aware that you can extract information from a text file using JS.
A possible approach could be:
for (var i = 0; i < musicFolder.length; i++) {
var object = new Object (
musicFolder[i].title,
musicFolder[i].path/src
);
objectArray.push(object);
}
I might need to somehow select an entire folder, but I am unsure how to achieve this in JS.