1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-14 23:33:31 +00:00

[PM-16447] Disable preserve whitespaces (#12994)

Angular 6 changed the default to not preserve whitespaces. We've continued to opt into this pattern for backwards compatibility but we're experiencing issues with the new control flow syntax and would therefore like to switch and not preserve whitespace any longer.
This commit is contained in:
Oscar Hinton
2025-02-18 17:05:29 +01:00
committed by GitHub
parent 7a7be6088a
commit dc606847e4
13 changed files with 7 additions and 24 deletions

View File

@@ -23,9 +23,7 @@ if (process.env.ENV === "production") {
}
function init() {
// FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling.
// eslint-disable-next-line @typescript-eslint/no-floating-promises
platformBrowserDynamic().bootstrapModule(AppModule, { preserveWhitespaces: true });
void platformBrowserDynamic().bootstrapModule(AppModule);
}
init();

View File

@@ -46,8 +46,7 @@
"useDefineForClassFields": false
},
"angularCompilerOptions": {
"strictTemplates": true,
"preserveWhitespaces": true
"strictTemplates": true
},
"include": [
"src",

View File

@@ -12,9 +12,7 @@ if (!ipc.platform.isDev) {
enableProdMode();
}
// FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling.
// eslint-disable-next-line @typescript-eslint/no-floating-promises
platformBrowserDynamic().bootstrapModule(AppModule, { preserveWhitespaces: true });
void platformBrowserDynamic().bootstrapModule(AppModule);
// Disable drag and drop to prevent malicious links from executing in the context of the app
document.addEventListener("dragover", (event) => event.preventDefault());

View File

@@ -45,8 +45,7 @@
"useDefineForClassFields": false
},
"angularCompilerOptions": {
"strictTemplates": true,
"preserveWhitespaces": true
"strictTemplates": true
},
"include": ["src", "../../libs/common/src/key-management/crypto/services/encrypt.worker.ts"]
}

View File

@@ -11,6 +11,4 @@ if (process.env.NODE_ENV === "production") {
enableProdMode();
}
// FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling.
// eslint-disable-next-line @typescript-eslint/no-floating-promises
platformBrowserDynamic().bootstrapModule(AppModule, { preserveWhitespaces: true });
void platformBrowserDynamic().bootstrapModule(AppModule);

View File

@@ -35,8 +35,7 @@
}
},
"angularCompilerOptions": {
"strictTemplates": true,
"preserveWhitespaces": true
"strictTemplates": true
},
"files": ["src/polyfills.ts", "src/main.ts", "src/theme.ts"],
"include": [