title: Get route parameters in component
body: <p>I am working on the Angular-6 project. I have many child routes for my application. One of them is as follow: </p>
  
  <pre><code>  const routes: Routes = [
    {
      path: 'innovation-track/:innovation-track-id', component: InnovationTrackComponent,
      children: [
        {
          path: 'sprint', component: ScrumBoardComponent
        }
      ]
    }
  ];
  </code></pre>
  
  <p>I want to get <strong>innovation-track-id</strong> value from URL in my <strong>ScrumBoardComponent</strong>.</p>
  
  <p>I know I can get this by doing following:</p>
  
  <pre><code> constructor(private _route: ActivatedRoute) { }
  
   //somewhere in method     
     this._route.snapshot.parent.paramMap
  </code></pre>
  
  <p>But, I want to fetch <strong>innovation-track-id</strong> value in any component, doesn't matter if it is child or parent. What I mean is I don't want to do the following:</p>
  
  <pre><code>this._route.snapshot.parent.paramMap
  </code></pre>
  
  <p>Instead, I want to do something as following: </p>
  
  <pre><code> this._route.params.&lt;any parameter name&gt;
  </code></pre>