Hide the content of app.component file from a single component in Angular

Discussão em 'Angular' iniciado por dr_nyt, Janeiro 31, 2025.

  1. dr_nyt

    dr_nyt Guest

    So I am trying to create an Angular app which will ask you to log in before accessing it. I am trying to keep the navbar in the app.component file so it is reused on all the components, but I want to get rid of it on the login page. I thought of just hiding it using CSS, but that might pose a security risk since the navbar will have other routes as well.

    I was also thinking of leaving the app.component idea and creat a child navbar component which will be reused in every component, but I'm not sure if that's the best way to do this. Any ideas are greatly appreciated.

    Continue reading...

Compartilhe esta Página