diff options
Diffstat (limited to 'client/src/app/environment.ts')
-rw-r--r-- | client/src/app/environment.ts | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/client/src/app/environment.ts b/client/src/app/environment.ts index 8bba89c4e..929e09490 100644 --- a/client/src/app/environment.ts +++ b/client/src/app/environment.ts | |||
@@ -4,19 +4,24 @@ | |||
4 | import { enableDebugTools, disableDebugTools } from '@angular/platform-browser'; | 4 | import { enableDebugTools, disableDebugTools } from '@angular/platform-browser'; |
5 | import { enableProdMode, ApplicationRef } from '@angular/core'; | 5 | import { enableProdMode, ApplicationRef } from '@angular/core'; |
6 | // Environment Providers | 6 | // Environment Providers |
7 | let PROVIDERS = [ | 7 | let PROVIDERS: any[] = [ |
8 | // common env directives | 8 | // common env directives |
9 | ]; | 9 | ]; |
10 | 10 | ||
11 | // Angular debug tools in the dev console | 11 | // Angular debug tools in the dev console |
12 | // https://github.com/angular/angular/blob/86405345b781a9dc2438c0fbe3e9409245647019/TOOLS_JS.md | 12 | // https://github.com/angular/angular/blob/86405345b781a9dc2438c0fbe3e9409245647019/TOOLS_JS.md |
13 | let _decorateModuleRef = function identity(value) { return value; }; | 13 | let _decorateModuleRef = function identity<T>(value: T): T { return value; }; |
14 | 14 | ||
15 | if ('production' === ENV) { | 15 | if ('production' === ENV) { |
16 | // Production | ||
17 | disableDebugTools(); | ||
18 | enableProdMode(); | 16 | enableProdMode(); |
19 | 17 | ||
18 | // Production | ||
19 | _decorateModuleRef = (modRef: any) => { | ||
20 | disableDebugTools(); | ||
21 | |||
22 | return modRef; | ||
23 | }; | ||
24 | |||
20 | PROVIDERS = [ | 25 | PROVIDERS = [ |
21 | ...PROVIDERS, | 26 | ...PROVIDERS, |
22 | // custom providers in production | 27 | // custom providers in production |