AngularJS - How to list the filenames from a given folder?
15,042
Angular is a client side library. Getting files from file directories is a backend capability.
Author by
Harsha Vardhan
Updated on July 05, 2022Comments
-
Harsha Vardhan almost 2 years
I have this folder/directory 'x' in the public folder of my application. Now I have path name till the folder i.e., /path/to/dir/x , but I don't know the names of the files in this directory. Now I need to provide URL links to the files in the html a tag's href attribute.
How do I list the name of the files in this directory?
-
GKFX about 8 yearsWelcome to StackOverflow! Thanks for this answer, but that's already been said in the first comment, so this doesn't add anything.
-
Sandor Rozsa over 6 yearsWrong! We have now 2017. We are using angular in electron that is running locally on desktop. So using the file system is a valid question.
-
palimboa over 5 years@SandorRozsa So is it possible?