Fixed scripts.

This commit is contained in:
Mike Cao 2023-08-25 15:06:47 -07:00
parent 8aaaa8dfd4
commit 35f80d9b00
4 changed files with 4 additions and 14 deletions

View File

@ -29,16 +29,6 @@ const aliasConfig = {
customResolver, customResolver,
}; };
const external = [
'react',
'react-dom',
'react/jsx-runtime',
'react-intl',
'react-basics',
'classnames',
'next',
];
const jsBundle = { const jsBundle = {
input: 'src/index.ts', input: 'src/index.ts',
output: [ output: [

View File

@ -4,7 +4,7 @@ const path = require('path');
const https = require('https'); const https = require('https');
const chalk = require('chalk'); const chalk = require('chalk');
const src = path.resolve(__dirname, '../lang'); const src = path.resolve(__dirname, '../src/lang');
const dest = path.resolve(__dirname, '../public/intl/country'); const dest = path.resolve(__dirname, '../public/intl/country');
const files = fs.readdirSync(src); const files = fs.readdirSync(src);

View File

@ -4,7 +4,7 @@ const path = require('path');
const https = require('https'); const https = require('https');
const chalk = require('chalk'); const chalk = require('chalk');
const src = path.resolve(__dirname, '../lang'); const src = path.resolve(__dirname, '../src/lang');
const dest = path.resolve(__dirname, '../public/intl/language'); const dest = path.resolve(__dirname, '../public/intl/language');
const files = fs.readdirSync(src); const files = fs.readdirSync(src);

View File

@ -3,7 +3,7 @@ const path = require('path');
const del = require('del'); const del = require('del');
const prettier = require('prettier'); const prettier = require('prettier');
const src = path.resolve(__dirname, '../lang'); const src = path.resolve(__dirname, '../src/lang');
const dest = path.resolve(__dirname, '../build/messages'); const dest = path.resolve(__dirname, '../build/messages');
const files = fs.readdirSync(src); const files = fs.readdirSync(src);
@ -17,7 +17,7 @@ async function run() {
await fs.ensureDir(dest); await fs.ensureDir(dest);
files.forEach(file => { files.forEach(file => {
const lang = require(`../lang/${file}`); const lang = require(`../src/lang/${file}`);
const keys = Object.keys(lang).sort(); const keys = Object.keys(lang).sort();
const formatted = keys.reduce((obj, key) => { const formatted = keys.reduce((obj, key) => {