feat: remove mobile styles

This commit is contained in:
email
2022-03-11 05:07:04 +08:00
parent b597d40470
commit 8f7445c299
35 changed files with 9 additions and 490 deletions

View File

@ -1,7 +1,6 @@
import { useContext, useEffect } from "react";
import { useContext } from "react";
import appContext from "./stores/appContext";
import { appRouterSwitch } from "./routers";
import { globalStateService } from "./services";
import "./less/app.less";
function App() {
@ -9,20 +8,6 @@ function App() {
locationState: { pathname },
} = useContext(appContext);
useEffect(() => {
const handleWindowResize = () => {
globalStateService.setIsMobileView(document.body.clientWidth <= 875);
};
handleWindowResize();
window.addEventListener("resize", handleWindowResize);
return () => {
window.removeEventListener("resize", handleWindowResize);
};
}, []);
return <>{appRouterSwitch(pathname)}</>;
}