import { useNavigate } from "react-router-dom";
export default function yourIndexPage({yourprops}) {
let navigate = useNavigate();
function changeLocation(placeToGo){
navigate(placeToGo, { replace: true });
window.location.reload();
}
return(
<ul className='menu'>
<li className="navbar-item">
<Link to="/inventory" onClick={() => changeLocation('/inventory')} className="nav-link">Complete Inventory</Link>
</li>
<li className="navbar-item">
<Link to="/inventory/clusters" onClick={() => changeLocation('/inventory/clusters')} className="nav-link">Inventory based on cluster</Link>
</li>
<li className="navbar-item">
<Link to="/inventory/clusters/servertype" onClick={() => changeLocation('/inventory/clusters/servertype')} className="nav-link">Inventory based on cluster and server type</Link>
</li>
</ul>
)
}