Skip to content

Commit 5b180b9

Browse files
authored
fix(Assets): exclude -fetch assets & remove unsupported Assets-static.js (#7344)
Fixes #7343
1 parent caaf50b commit 5b180b9

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

packages/main/scripts/generateI18n.mjs

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -54,18 +54,14 @@ spawnSync('npx', ['prettier', '--write', path.resolve(SRC_I18N_PROPERTIES, 'i18n
5454
stdio: [0, 1, 2],
5555
});
5656

57-
// generate Assets.js and Assets-static.js
57+
// generate Assets.js
5858
const jsonImports = await readdir(TARGET_I18N_JSON_IMPORTS);
5959

6060
const assets = [`import '@ui5/webcomponents/dist/Assets.js';`, `import '@ui5/webcomponents-fiori/dist/Assets.js';`];
61-
const assetsStatic = [
62-
`import '@ui5/webcomponents/dist/Assets-static.js';`,
63-
`import '@ui5/webcomponents-fiori/dist/Assets-static.js';`,
64-
];
6561

6662
for (const file of jsonImports) {
67-
if (file.includes('-static')) {
68-
assetsStatic.push(`import './json-imports/${file}';`);
63+
if (file.includes('-fetch')) {
64+
//todo: add to Assets-fetch.js
6965
} else {
7066
assets.push(`import './json-imports/${file}';`);
7167
}
@@ -75,7 +71,3 @@ await writeFile(
7571
path.resolve(DIST_DIR, 'Assets.js'),
7672
await prettier.format(assets.join('\n'), { ...prettierConfig, parser: 'babel' }),
7773
);
78-
await writeFile(
79-
path.resolve(DIST_DIR, 'Assets-static.js'),
80-
await prettier.format(assetsStatic.join('\n'), { ...prettierConfig, parser: 'babel' }),
81-
);

0 commit comments

Comments
 (0)