Skip to content

Commit 0594016

Browse files
committed
fixup! perf(@angular/build): avoid loading compiler-cli and typescript in js transform worker
1 parent 3deb68f commit 0594016

1 file changed

Lines changed: 18 additions & 7 deletions

File tree

‎packages/angular/build/src/tools/angular/linker/oxc-linker.ts‎

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -47,18 +47,29 @@ const noopFileSystem: ReadonlyFileSystem = {
4747

4848
const defaultLogger: Logger = {
4949
level: 1, // LogLevel.info
50-
debug() {},
50+
debug(...args: string[]) {
51+
if (this.level <= 0) {
52+
// eslint-disable-next-line no-console
53+
console.debug(...args);
54+
}
55+
},
5156
info(...args: string[]) {
52-
// eslint-disable-next-line no-console
53-
console.info(...args);
57+
if (this.level <= 1) {
58+
// eslint-disable-next-line no-console
59+
console.info(...args);
60+
}
5461
},
5562
warn(...args: string[]) {
56-
// eslint-disable-next-line no-console
57-
console.warn(...args);
63+
if (this.level <= 2) {
64+
// eslint-disable-next-line no-console
65+
console.warn(...args);
66+
}
5867
},
5968
error(...args: string[]) {
60-
// eslint-disable-next-line no-console
61-
console.error(...args);
69+
if (this.level <= 3) {
70+
// eslint-disable-next-line no-console
71+
console.error(...args);
72+
}
6273
},
6374
};
6475

0 commit comments

Comments
 (0)