diff --git a/router/src/app/app-routing.module.ts b/router/src/app/app-routing.module.ts index bdcaba0..e7db1e1 100644 --- a/router/src/app/app-routing.module.ts +++ b/router/src/app/app-routing.module.ts @@ -11,7 +11,7 @@ const routes: Routes = [ component: AboutComponent }, { - path: 'resume', + path: 'resume/:id', component: ResumeComponent }, { diff --git a/url_params.md b/url_params.md index 4855952..15cf655 100644 --- a/url_params.md +++ b/url_params.md @@ -81,3 +81,24 @@ In `src/app.app.component.html` loop through the jobs to create links: ``` + +## Alter the resume route to accept params + +Our resume route in `src/app/app-routing.module.ts` no longer works. Update it to accept params: + +```javascript +const routes: Routes = [ + { + path: 'about', + component: AboutComponent + }, + { + path: 'resume/:id', + component: ResumeComponent + }, + { + path: 'links', + component: LinksComponent + } +]; +```