@eui/tools 6.12.50 → 6.12.52
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.version.properties +1 -1
- package/CHANGELOG.md +18 -0
- package/package.json +1 -1
- package/scripts/csdr/init/resources/14.x/resolutions.json +1 -2
- package/scripts/csdr/init/resources/14.x/yarn.lock +1081 -10592
- package/scripts/csdr/init/resources/14.x/{yarn.lock.temp → yarn.lock.old} +825 -214
- package/scripts/utils/pre-build/routes-replacement/routes-replacement.js +18 -5
|
@@ -294,9 +294,22 @@ const getProjectRoutes = (project, routesDefs) => {
|
|
|
294
294
|
// those files are also generated based on the route "lazyDefs" data definition
|
|
295
295
|
|
|
296
296
|
if (route.lazy) {
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
297
|
+
let lazyLoadDef = null;
|
|
298
|
+
|
|
299
|
+
if (Array.isArray(defRoute.lazyLoadDef)) {
|
|
300
|
+
lazyLoadDef = defRoute.lazyLoadDef.filter(lld => lld.euiVersion === euiVersion)[0];
|
|
301
|
+
} else {
|
|
302
|
+
lazyLoadDef = defRoute.lazyLoadDef;
|
|
303
|
+
}
|
|
304
|
+
|
|
305
|
+
if (!lazyLoadDef) {
|
|
306
|
+
console.log(`Unable to find lazyLoadDef route for path : ${defRoute.path}`);
|
|
307
|
+
throw new Error('LAZY_ROUTE_DEF_NOT_FOUND');
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
const scopeName = lazyLoadDef.npmPkg.split('/')[0].substr(1);
|
|
311
|
+
const pkgName = lazyLoadDef.npmPkg.split('/')[1];
|
|
312
|
+
const lazyFeatureLibName = `${scopeName}-${pkgName}-${lazyLoadDef.moduleName}.lib.module`;
|
|
300
313
|
|
|
301
314
|
if (euiVersion === '10.x') {
|
|
302
315
|
loadChildrenGenerated = `loadChildren: "./features/${lazyFeatureLibName}#Module"`;
|
|
@@ -306,8 +319,8 @@ const getProjectRoutes = (project, routesDefs) => {
|
|
|
306
319
|
|
|
307
320
|
lazyLibDef = {
|
|
308
321
|
filename: `${lazyFeatureLibName}.ts`,
|
|
309
|
-
npmPkg:
|
|
310
|
-
moduleName:
|
|
322
|
+
npmPkg: lazyLoadDef.npmPkg,
|
|
323
|
+
moduleName: lazyLoadDef.moduleName,
|
|
311
324
|
};
|
|
312
325
|
|
|
313
326
|
// if the route is a remote, the elementLoader is then used as a default feature module loaded
|