diff --git a/src/app/core/utils/routing.ts b/src/app/core/utils/routing.ts index 2694e0daa55..16b00f7d584 100644 --- a/src/app/core/utils/routing.ts +++ b/src/app/core/utils/routing.ts @@ -39,8 +39,8 @@ export function sanitizeSlugData(slugData: string) { .replace(/-+/g, '-') .replace(/-+$/, '') .toLowerCase() - .replace('pg', 'Pg') - .replace('prd', 'Prd') - .replace('ctg', 'Ctg') || '' + .replaceAll('pg', 'Pg') + .replaceAll('prd', 'Prd') + .replaceAll('ctg', 'Ctg') || '' ); } diff --git a/src/app/pages/app-last-routing.module.ts b/src/app/pages/app-last-routing.module.ts index 7feb454e115..0b476f44b9c 100644 --- a/src/app/pages/app-last-routing.module.ts +++ b/src/app/pages/app-last-routing.module.ts @@ -7,10 +7,6 @@ import { matchContentRoute } from 'ish-core/routing/content-page/content-page.ro import { matchProductRoute } from 'ish-core/routing/product/product.route'; const routes: Routes = [ - { - matcher: matchContentRoute, - loadChildren: () => import('./content/content-page.module').then(m => m.ContentPageModule), - }, { matcher: matchProductRoute, loadChildren: () => import('./product/product-page.module').then(m => m.ProductPageModule), @@ -19,6 +15,10 @@ const routes: Routes = [ matcher: matchCategoryRoute, loadChildren: () => import('./category/category-page.module').then(m => m.CategoryPageModule), }, + { + matcher: matchContentRoute, + loadChildren: () => import('./content/content-page.module').then(m => m.ContentPageModule), + }, { path: '**', canActivate: [notFoundStatusGuard], diff --git a/tsconfig.json b/tsconfig.json index 52363edab7e..fb639aba861 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -9,7 +9,7 @@ "downlevelIteration": true, "experimentalDecorators": true, "emitDecoratorMetadata": true, - "module": "CommonJS", + "module": "ES2022", "moduleResolution": "node", "importHelpers": true, "target": "ES2022", @@ -25,7 +25,7 @@ ], "swiper_angular": ["node_modules/swiper/angular"] }, - "lib": ["es2018", "dom"], + "lib": ["ES2022", "dom"], "noUnusedLocals": true, "noUnusedParameters": true, "noImplicitAny": true,