]>
Commit | Line | Data |
---|---|---|
1 | import { NgModule } from '@angular/core' | |
2 | import { RouterModule, Routes } from '@angular/router' | |
3 | import { VideoWatchComponent } from './video-watch.component' | |
4 | ||
5 | const videoWatchRoutes: Routes = [ | |
6 | { | |
7 | path: 'p/:playlistId', | |
8 | component: VideoWatchComponent | |
9 | }, | |
10 | { | |
11 | path: ':videoId/comments/:commentId', | |
12 | redirectTo: ':videoId' | |
13 | }, | |
14 | { | |
15 | path: ':videoId', | |
16 | component: VideoWatchComponent | |
17 | } | |
18 | ] | |
19 | ||
20 | @NgModule({ | |
21 | imports: [ RouterModule.forChild(videoWatchRoutes) ], | |
22 | exports: [ RouterModule ] | |
23 | }) | |
24 | export class VideoWatchRoutingModule {} |