aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/main.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-07-15 15:30:14 +0200
committerChocobozzz <me@florianbigard.com>2022-07-18 11:37:18 +0200
commit42b40636991b97fe818007fab19091764fc5db73 (patch)
treedb431787c06ce898d22e91ff771f795219274fc6 /client/src/main.ts
parent654d4ede7fa4d0faa71e49bcfab6b65a686397b2 (diff)
downloadPeerTube-42b40636991b97fe818007fab19091764fc5db73.tar.gz
PeerTube-42b40636991b97fe818007fab19091764fc5db73.tar.zst
PeerTube-42b40636991b97fe818007fab19091764fc5db73.zip
Add ability for client to create server logs
Diffstat (limited to 'client/src/main.ts')
-rw-r--r--client/src/main.ts5
1 files changed, 4 insertions, 1 deletions
diff --git a/client/src/main.ts b/client/src/main.ts
index 84c82203d..432db0eac 100644
--- a/client/src/main.ts
+++ b/client/src/main.ts
@@ -3,11 +3,14 @@ import { enableDebugTools } from '@angular/platform-browser'
3import { platformBrowserDynamic } from '@angular/platform-browser-dynamic' 3import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'
4import { AppModule } from './app/app.module' 4import { AppModule } from './app/app.module'
5import { environment } from './environments/environment' 5import { environment } from './environments/environment'
6import { logger } from './root-helpers'
6 7
7if (environment.production) { 8if (environment.production) {
8 enableProdMode() 9 enableProdMode()
9} 10}
10 11
12logger.registerServerSending(environment.apiUrl)
13
11const bootstrap = () => platformBrowserDynamic() 14const bootstrap = () => platformBrowserDynamic()
12 .bootstrapModule(AppModule) 15 .bootstrapModule(AppModule)
13 .then(bootstrapModule => { 16 .then(bootstrapModule => {
@@ -22,7 +25,7 @@ const bootstrap = () => platformBrowserDynamic()
22 return bootstrapModule 25 return bootstrapModule
23 }) 26 })
24 .catch(err => { 27 .catch(err => {
25 console.error(err) 28 logger.error(err)
26 return null 29 return null
27 }) 30 })
28 31