How do i get the names of a files in a folder in React js

79 views Asked by At

I need to get a list of file names in a folder. The react project was created using vite. The needed file dir is src/data/(the json files which i need the name of).

I know that there is fs and list-react-files but they do not work.

0

There are 0 answers