Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

105
Vistas
Angular Ngoninit getting called everytime while routing

I have one component Details where the routes for other child components is there. What is happening is that when I route to any other child component then the onint of the Details is getting called.

For Example- example.com/details/123123123/profile is my current route

I am navigating to example.com/details/12312331/pastappointment

then the NgOnInit of Details is getting called. Which is calling all the apis that I don't want.

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

You have to use

<router-outlet></router-outlet> 

inside your Details component.

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda