Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

__dirname is not defined

import { fileURLToPath } from 'url';
import { dirname } from 'path';

const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #defined
ADD COMMENT
Topic
Name
3+3 =