Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit f91cfb2

Browse files
committed
CORE-287 off sidebar toggler
1 parent 3f068ca commit f91cfb2

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/App.jsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
/**
22
* Main App component
33
*/
4-
import React, { useEffect, useRef } from "react";
4+
import React, { useLayoutEffect, useEffect, useRef } from "react";
55
import { Router, useLocation } from "@reach/router";
6+
import { disableSidebarForRoute } from "@topcoder/mfe-header";
67
import _ from "lodash";
78
import { usePreviousLocation } from "./utils/hooks";
89
import Parcel from "single-spa-react/parcel";
@@ -16,6 +17,11 @@ import Menu from "./containers/Menu";
1617
const App = () => {
1718
const menuVisible = useSelector((state) => state.menu.show);
1819

20+
useLayoutEffect(() => {
21+
disableSidebarForRoute("/earn/*");
22+
document.title = "Listings-EARN-Topcoder";
23+
}, []);
24+
1925
const location = useLocation();
2026
const previousLocation = usePreviousLocation();
2127

0 commit comments

Comments
 (0)