As shown in my ugly looking Flowchart, I want to hide the Header component if Main component renders the Login component. But if the Main component renders the Home component, I want to display the Header component. The Main.js has a conditional operator that returns either Home component or Login component.
Putting the Header Component in Home itself will not solve the problem as I have to add much more pages and adding a Header component in every page doesn't seem efficient.
Aucun commentaire:
Enregistrer un commentaire