mirror of
https://github.com/chillpadclub/bedolaga-cabinet.git
synced 2026-07-28 09:33:46 +00:00
perf: eagerly load Dashboard to improve LCP on main route
Dashboard is the default landing page for all authenticated users. Loading it eagerly eliminates one extra network round-trip for the JS chunk (+30KB / +7KB gzip to main bundle, but saves ~200-500ms of chunk fetch + parse time on first load).
This commit is contained in:
@@ -21,8 +21,10 @@ import VerifyEmail from './pages/VerifyEmail';
|
||||
import ResetPassword from './pages/ResetPassword';
|
||||
import OAuthCallback from './pages/OAuthCallback';
|
||||
|
||||
// Dashboard - load eagerly (default route, LCP-critical)
|
||||
import Dashboard from './pages/Dashboard';
|
||||
|
||||
// User pages - lazy load
|
||||
const Dashboard = lazy(() => import('./pages/Dashboard'));
|
||||
const Subscription = lazy(() => import('./pages/Subscription'));
|
||||
const Balance = lazy(() => import('./pages/Balance'));
|
||||
const Referral = lazy(() => import('./pages/Referral'));
|
||||
|
||||
Reference in New Issue
Block a user