so ive been trying to fix this problem for the past hour and can get it to work, its probably a stupid mistake, but what you see here is my fs.readdir is defined.
Question posted in Visual Studio Code
View the official documentation.
View the official documentation.
2
Answers
You need to import fs. Put this above line 25 or your first use of
fs
If you still don’t install the
fs
package, go to terminal then typenpm install fs
Ctrl + C
if your bot is runningnpm install fs
ornpm i fs
const fs = require('fs');
You can put it on line 13 in your
js file