I have the following in /pages/index.js:
export default function Home() {
return (
<div className={styles.grid_container}>
<NavBar/>
<div className={styles.center_pane}>
<Overview/>
</div>
<div className={styles.right_pane}>
<h2>Right Pane</h2>
</div>
<Footer/>
</div>
)
}
It renders everything fine but I need some way of parameterizing the <Overview/>
element so that depending on what page the user navigates to from the <Navbar>
it will render the corresponding component.
The option I was considering was just creating a page for each link but seems very inefficient.
This question seemed very similar but it never recieved an answer: Nextjs: render content based on sidebar choice
Any help would be appreciated, thanks.