Remove fs-extra dependency in favor of native node:fs

This commit is contained in:
Mike Cao
2026-03-29 23:12:45 -04:00
parent 224bbbb8de
commit c4e52e7dcd
5 changed files with 962 additions and 995 deletions
+2 -2
View File
@@ -3,7 +3,7 @@
import https from 'node:https';
import path from 'node:path';
import chalk from 'chalk';
import fs from 'fs-extra';
import fs from 'node:fs';
const src = path.resolve(process.cwd(), 'public/intl/messages');
const dest = path.resolve(process.cwd(), 'public/intl/country');
@@ -43,7 +43,7 @@ const downloadFile = (url, filepath) =>
});
const download = async files => {
await fs.ensureDir(dest);
fs.mkdirSync(dest, { recursive: true });
await asyncForEach(files, async file => {
const locale = file.replace('-', '_').replace('.json', '');
+2 -2
View File
@@ -3,7 +3,7 @@
import https from 'node:https';
import path from 'node:path';
import chalk from 'chalk';
import fs from 'fs-extra';
import fs from 'node:fs';
const src = path.resolve(process.cwd(), 'public/intl/messages');
const dest = path.resolve(process.cwd(), 'public/intl/language');
@@ -43,7 +43,7 @@ const downloadFile = (url, filepath) =>
});
const download = async files => {
await fs.ensureDir(dest);
fs.mkdirSync(dest, { recursive: true });
await asyncForEach(files, async file => {
const locale = file.replace('-', '_').replace('.json', '');