Referenceerror: __dirname не определено
import path from 'path';
const __dirname = path.resolve();
Charming Cormorant
import path from 'path';
const __dirname = path.resolve();
import { fileURLToPath } from 'url';
import { dirname } from 'path';
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);