2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-22 06:40:54 +00:00

Fix reloading on viewport size change ()

This commit is contained in:
Lukas
2023-11-30 05:53:32 +01:00
committed by GitHub
parent e4c5bfc2fe
commit 0cd66fd16c

@ -25,15 +25,16 @@ function checkMobile() {
return false;
}
const MobileAppView = Loadable(lazy(() => import('./views/MobileAppView')));
const DesktopAppView = Loadable(lazy(() => import('./views/DesktopAppView')));
// Main App
export default function App() {
// Check if mobile
if (checkMobile()) {
const MobileAppView = Loadable(lazy(() => import('./views/MobileAppView')));
return <MobileAppView />;
}
// Main App component
const DesktopAppView = Loadable(lazy(() => import('./views/DesktopAppView')));
return <DesktopAppView />;
}