__dirname is not defined
snippet in javascript

__dirname is not defined

user8885

const __dirname = path.resolve(path.dirname('')); 
// Add this code to your file to create __dirname if it is not defined