Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

103
Views
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 answers
Answer question

0

You have to use

<router-outlet></router-outlet> 

inside your Details component.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!