Created
October 25, 2021 10:50
-
-
Save vojty/4c4acc3a087b583644a25ea19b0c93ab to your computer and use it in GitHub Desktop.
__dirname with ESM modules
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import path from 'path' | |
const __dirname = path.dirname(fileURLToPath(import.meta.url)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment