1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-07-17 13:46:47 +02:00
unleash.unleash/frontend/src/hooks/useNewAdminMenu.ts
2025-05-06 14:59:07 +02:00

11 lines
284 B
TypeScript

import { useLocation } from 'react-router';
export const useNewAdminMenu = () => {
const location = useLocation();
return {
showOnlyAdminMenu:
location.pathname.indexOf('/admin') === 0 ||
location.pathname.indexOf('/history') === 0,
};
};