mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
ui: use common upload function
This commit is contained in:
1 parent
b48dc5344a
commit
803c3f4925
8 files changed
+113
-260
No files matched your search
@@ -56,7 +56,10 @@ async function runWebpack({
|
||||
for (const file of files) {
|
||||
if (!file.isFile() || file.name.endsWith('.map')) continue;
|
||||
const data = await fs.stat(path.join(root('public'), file.name));
|
||||
stats[file.name.replace(/\.[a-f0-9]{10}\./, '.')] = data.size;
|
||||
const key = file.name
|
||||
.replace(/\.[a-f0-9]{4}\.chunk\./, '.chunk.')
|
||||
.replace(/\.[a-f0-9]{4}\.worker\./, '.worker.');
|
||||
stats[key] = data.size;
|
||||
}
|
||||
const statsPath = root('__bundleInfo');
|
||||
if (fs.existsSync(statsPath)) {
|
||||
|
||||
Reference in new issue
Block a user