We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent de25e98 commit e243689Copy full SHA for e243689
scripts/fix-imports.js
@@ -1,7 +1,10 @@
1
#!/usr/bin/env node
2
3
-const fs = require('fs');
4
-const path = require('path');
+import fs from 'fs';
+import path from 'path';
5
+import { fileURLToPath } from 'url';
6
+
7
+const __dirname = path.dirname(fileURLToPath(import.meta.url));
8
9
function fixImports(dir) {
10
const files = fs.readdirSync(dir);
0 commit comments