fClaude/improve app loading speed 12n cr#53
Open
Marviel wants to merge 3 commits into
Open
Conversation
…ndle size - Replace blank screen (null) in ClientOnly with a loading spinner so users see immediate visual feedback during hydration - Show themed loading spinner in AppProviderWrapper while Apollo client initializes instead of rendering nothing - Lazy-load PostHog analytics via dynamic import() to remove ~100KB from the critical rendering path - Dynamic import VoronoiBackgroundDefault on home page to defer loading the Delaunator geometry library - Remove unused imports: lodash from _baseLayout and useRsnUser, async-mutex from _baseLayout, useEffectDeepEqual from useRsnUser - Remove three empty useEffectDeepEqual hooks in useRsnUser that ran on every state change but only contained commented-out console.debug calls - Cache browser timezone string at module level to avoid repeated Intl.DateTimeFormat() lookups during auth flow https://claude.ai/code/session_01VaJKr53J9VeZTBUsuWSXxL
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Review by RecurseML
🔍 Review performed on 97546a8..93af00f
✨ No bugs found, your code is sparkling clean
✅ Files analyzed, no issues (5)
• apps/next-main/app/app/page.page.tsx
• apps/next-main/app/app/skillsets/[skillSetId]/tree/page.page.tsx
• apps/next-main/clientOnly/hooks/useRsnUser.ts
• apps/next-main/components/ClientOnly.tsx
• apps/next-main/components/_APP/_baseLayout.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
High-level PR Summary
This PR optimizes application loading speed through several strategic improvements: lazy-loading heavy dependencies using Next.js
dynamic()imports (VoronoiBackground, ReactFlowProvider, posthog), caching browser timezone lookups to avoid repeatedIntlAPI calls, removing unused dependencies (lodash, useEffectDeepEqual), and adding loading fallbacks to prevent blank screens during initial render. The changes focus on deferring non-critical resources off the critical rendering path while maintaining functionality.⏱️ Estimated Review Time: 15-30 minutes
💡 Review Order Suggestion
apps/next-main/components/ClientOnly.tsxapps/next-main/clientOnly/hooks/useRsnUser.tsapps/next-main/components/_APP/_baseLayout.tsxapps/next-main/app/app/page.page.tsxapps/next-main/app/app/skillsets/[skillSetId]/tree/page.page.tsx