aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/app.module.ts
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/app/app.module.ts')
-rw-r--r--client/src/app/app.module.ts13
1 files changed, 7 insertions, 6 deletions
diff --git a/client/src/app/app.module.ts b/client/src/app/app.module.ts
index cae99786b..77d68a4ec 100644
--- a/client/src/app/app.module.ts
+++ b/client/src/app/app.module.ts
@@ -1,6 +1,7 @@
1import { NgModule } from '@angular/core' 1import { NgModule } from '@angular/core'
2import { BrowserModule } from '@angular/platform-browser' 2import { BrowserModule } from '@angular/platform-browser'
3import { AboutModule } from '@app/about' 3import { AboutModule } from '@app/about'
4import { ServerService } from '@app/core'
4import { ResetPasswordModule } from '@app/reset-password' 5import { ResetPasswordModule } from '@app/reset-password'
5 6
6import { MetaLoader, MetaModule, MetaStaticLoader, PageTitlePositioning } from '@ngx-meta/core' 7import { MetaLoader, MetaModule, MetaStaticLoader, PageTitlePositioning } from '@ngx-meta/core'
@@ -17,15 +18,14 @@ import { SharedModule } from './shared'
17import { SignupModule } from './signup' 18import { SignupModule } from './signup'
18import { VideosModule } from './videos' 19import { VideosModule } from './videos'
19 20
20export function metaFactory (): MetaLoader { 21export function metaFactory (serverService: ServerService): MetaLoader {
21 return new MetaStaticLoader({ 22 return new MetaStaticLoader({
22 pageTitlePositioning: PageTitlePositioning.PrependPageTitle, 23 pageTitlePositioning: PageTitlePositioning.PrependPageTitle,
23 pageTitleSeparator: ' - ', 24 pageTitleSeparator: ' - ',
24 applicationName: 'PeerTube', 25 get applicationName () { return serverService.getConfig().instance.name },
25 defaults: { 26 defaults: {
26 title: 'PeerTube', 27 get title () { return serverService.getConfig().instance.name },
27 description: 'PeerTube, a federated (ActivityPub) video streaming platform ' + 28 get description () { return serverService.getConfig().instance.shortDescription }
28 'using P2P (BitTorrent) directly in the web browser with WebTorrent and Angular. '
29 } 29 }
30 }) 30 })
31} 31}
@@ -57,7 +57,8 @@ export function metaFactory (): MetaLoader {
57 57
58 MetaModule.forRoot({ 58 MetaModule.forRoot({
59 provide: MetaLoader, 59 provide: MetaLoader,
60 useFactory: (metaFactory) 60 useFactory: (metaFactory),
61 deps: [ ServerService ]
61 }) 62 })
62 ], 63 ],
63 providers: [ ] 64 providers: [ ]