title: Angular render component depending on url
body: <p>I have an Angular 9 single page website. This page contain multiple component rendered with angular universal. All blocks are rendered one after another.</p>
  <p>Let's say I have these component: header, services, contact, footer.
  In my header I have a link to all component as anchor.</p>
  <p>To optimize my SEO, I would like to render all block for users, but only the block linked to the anchor for search engine crawlers.</p>
  <p>For example,on mywebsite.com/contact :
  As an user I would render all component but I would be at the contact anchor.
  As a crawler, I would only render header, contact and footer</p>
  <p>I searched everywhere but I cant find a way to do that properly, even that it seems like a thing everyone who want to optimize their SEO should do.</p>
  <p>Am I missing something or do you have a way to do that ?</p>
  <p><strong>EDIT :</strong></p>
  <p>By using ng-template I can show one component or all with a condition.</p>
  <p>For this condition I need to get the user agent but I cant find a way to get it with Angular Universal.
  navigator.userAgent doesn't work since it's the website is rendered by the server.</p>
  <p>Since I'm new to Angular I dont know how to get that information. Any help ?</p>