]>
Commit | Line | Data |
---|---|---|
63c4db6d | 1 | import { NgModule } from '@angular/core' |
df98563e | 2 | import { BrowserModule } from '@angular/platform-browser' |
7193ad10 | 3 | import { ServiceWorkerModule } from '@angular/service-worker' |
36f9424f | 4 | import { AboutModule } from '@app/about' |
ecb4e35f | 5 | import { ResetPasswordModule } from '@app/reset-password' |
ab32b0fc | 6 | |
ecb4e35f | 7 | import { MetaLoader, MetaModule, MetaStaticLoader, PageTitlePositioning } from '@ngx-meta/core' |
7193ad10 | 8 | import { environment } from '../environments/environment' |
ecb4e35f C |
9 | |
10 | import { AccountModule } from './account' | |
b58c69a1 | 11 | |
df98563e C |
12 | import { AppRoutingModule } from './app-routing.module' |
13 | import { AppComponent } from './app.component' | |
df98563e | 14 | import { CoreModule } from './core' |
ecb4e35f | 15 | import { HeaderComponent } from './header' |
df98563e | 16 | import { LoginModule } from './login' |
ecb4e35f | 17 | import { MenuComponent } from './menu' |
df98563e | 18 | import { SharedModule } from './shared' |
ecb4e35f | 19 | import { SignupModule } from './signup' |
df98563e | 20 | import { VideosModule } from './videos' |
693b1aba | 21 | |
df98563e | 22 | export function metaFactory (): MetaLoader { |
758b996d C |
23 | return new MetaStaticLoader({ |
24 | pageTitlePositioning: PageTitlePositioning.PrependPageTitle, | |
25 | pageTitleSeparator: ' - ', | |
26 | applicationName: 'PeerTube', | |
27 | defaults: { | |
28 | title: 'PeerTube', | |
7193ad10 C |
29 | description: 'PeerTube, a federated (ActivityPub) video streaming platform ' + |
30 | 'using P2P (BitTorrent) directly in the web browser with WebTorrent and Angular. ' | |
758b996d | 31 | } |
df98563e | 32 | }) |
758b996d | 33 | } |
b58c69a1 | 34 | |
ab32b0fc C |
35 | @NgModule({ |
36 | bootstrap: [ AppComponent ], | |
37 | declarations: [ | |
b33f657c C |
38 | AppComponent, |
39 | ||
40 | MenuComponent, | |
f3aaa9a9 | 41 | HeaderComponent |
ab32b0fc | 42 | ], |
693b1aba | 43 | imports: [ |
ab32b0fc | 44 | BrowserModule, |
23bcf666 | 45 | |
693b1aba C |
46 | CoreModule, |
47 | SharedModule, | |
48 | ||
49 | AppRoutingModule, | |
b58c69a1 | 50 | |
693b1aba | 51 | AccountModule, |
693b1aba C |
52 | CoreModule, |
53 | LoginModule, | |
ecb4e35f | 54 | ResetPasswordModule, |
a184c71b | 55 | SignupModule, |
693b1aba | 56 | SharedModule, |
55b33946 | 57 | VideosModule, |
36f9424f | 58 | AboutModule, |
55b33946 C |
59 | |
60 | MetaModule.forRoot({ | |
61 | provide: MetaLoader, | |
62 | useFactory: (metaFactory) | |
7193ad10 C |
63 | }), |
64 | ||
65 | ServiceWorkerModule.register('/ngsw-worker.js', { enabled: environment.production }) | |
ab32b0fc | 66 | ], |
63c4db6d | 67 | providers: [ ] |
ab32b0fc | 68 | }) |
63c4db6d | 69 | export class AppModule {} |