From 582722234c4e7193cd539f8a6f2542dc2df1f8f1 Mon Sep 17 00:00:00 2001 From: Olivier Combe Date: Fri, 1 Dec 2023 22:26:21 +0100 Subject: [PATCH] fix: default value for `normalizePath` --- angular/devkit/common/utils.ts | 2 +- angular/templates/generators/ng-app/index.ts | 2 +- angular/templates/generators/ng-app/template-files/index.ts | 3 +-- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/angular/devkit/common/utils.ts b/angular/devkit/common/utils.ts index 48a85357..d1659c9c 100644 --- a/angular/devkit/common/utils.ts +++ b/angular/devkit/common/utils.ts @@ -245,7 +245,7 @@ export function packagePath(packageName: string, path = ''): string { * Normalize slashes in a file path to be posix/unix-like forward slashes. * Also condenses repeat slashes to a single slash and removes and trailing slashes, unless disabled. */ -export function normalizePath(path: string, removeTrailingSlashes = false): string { +export function normalizePath(path: string = '', removeTrailingSlashes = false): string { return normalize(path, removeTrailingSlashes); } diff --git a/angular/templates/generators/ng-app/index.ts b/angular/templates/generators/ng-app/index.ts index 76ab5e1d..4a1b90e2 100644 --- a/angular/templates/generators/ng-app/index.ts +++ b/angular/templates/generators/ng-app/index.ts @@ -76,7 +76,7 @@ export class NgAppTemplate implements ComponentTemplate { let params: { [id: string]: any } = { styleSheet: 'scss', standalone: this.angularVersion > 13, - ssr: this.angularVersion >= 17 // todo: check if we can use 16 here + ssr: this.angularVersion >= 17 }; if (!isCI) { diff --git a/angular/templates/generators/ng-app/template-files/index.ts b/angular/templates/generators/ng-app/template-files/index.ts index 8a7c7567..51fe4022 100644 --- a/angular/templates/generators/ng-app/template-files/index.ts +++ b/angular/templates/generators/ng-app/template-files/index.ts @@ -5,7 +5,6 @@ export const indexFile = (context: ComponentContext): ComponentFile => { return { relativePath: `index.ts`, isMain: true, - content: `export * from './${name}.ng-app'; -` + content: `export * from './${name}.ng-app';` }; };