diff --git a/utils/convert.js b/utils/convert.js index 15bc9d82..9486ae7b 100755 --- a/utils/convert.js +++ b/utils/convert.js @@ -5,12 +5,15 @@ import { program } from 'commander'; import fs from 'fs'; import fse from 'fs-extra'; import babel from '@babel/core'; +import { fileURLToPath } from 'url'; program .option('-m, --with-source-maps [type]', 'output source maps when not generating a bundled app (type may be empty for external source maps, inline for inline source maps, or both) ') .option('--clean', 'clear the lib folder before building') .parse(process.argv); +const __dirname = path.dirname(fileURLToPath(import.meta.url)); + // the various important paths const paths = { main: path.resolve(__dirname, '..'),