-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add goal info to the prewarm list #3514
Conversation
WalkthroughThe pull request introduces additional data retrieval in the asynchronous handler functions Changes
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
✅ Deploy Preview for actualbudget ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Bundle Stats — desktop-clientHey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle. As this PR is updated, I'll keep you updated on how the bundle size is impacted. Total
Changeset No files were changed View detailed bundle breakdownAdded No assets were added Removed No assets were removed Bigger No assets were bigger Smaller No assets were smaller Unchanged
|
Bundle Stats — loot-coreHey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle. As this PR is updated, I'll keep you updated on how the bundle size is impacted. Total
Changeset
View detailed bundle breakdownAdded No assets were added Removed No assets were removed Bigger
Smaller No assets were smaller Unchanged No assets were unchanged |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Outside diff range and nitpick comments (2)
packages/loot-core/src/server/main.ts (2)
221-222
: Enhance goal data prewarming in envelope-budget-monthThe addition of
goal-${cat.id}
andlong-goal-${cat.id}
to thevalues
array aligns with the PR objective of enhancing the loading speed of goal indicators on the budget page. This change should ensure that goal data is ready for use concurrently with the balance data.Consider adding a trailing comma after the last item in the array for consistency and to make future additions easier:
value(`goal-${cat.id}`), -value(`long-goal-${cat.id}`) +value(`long-goal-${cat.id}`),🧰 Tools
🪛 GitHub Check: lint
[warning] 222-222:
Insert,
262-263
: Enhance goal data prewarming in tracking-budget-monthThe addition of
goal-${cat.id}
andlong-goal-${cat.id}
to thevalues
array in thetracking-budget-month
function maintains consistency with the changes made inenvelope-budget-month
. This ensures that goal data is prewarmed for both envelope and tracking budgets.Consider adding a trailing comma after the last item in the array for consistency and to make future additions easier:
value(`goal-${cat.id}`), -value(`long-goal-${cat.id}`) +value(`long-goal-${cat.id}`),🧰 Tools
🪛 GitHub Check: lint
[warning] 263-263:
Insert,
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
⛔ Files ignored due to path filters (1)
upcoming-release-notes/3514.md
is excluded by!**/*.md
📒 Files selected for processing (1)
- packages/loot-core/src/server/main.ts (2 hunks)
🧰 Additional context used
🪛 GitHub Check: lint
packages/loot-core/src/server/main.ts
[warning] 222-222:
Insert,
[warning] 263-263:
Insert,
🔇 Additional comments (1)
packages/loot-core/src/server/main.ts (1)
221-222
: Summary: Improved goal data prewarming for faster loadingThe changes in both
envelope-budget-month
andtracking-budget-month
functions successfully add goal-related data (goal-${cat.id}
andlong-goal-${cat.id}
) to the prewarming process. This enhancement aligns well with the PR objectives and should improve the loading speed of goal indicators on the budget page.Key points:
- Consistent implementation across both envelope and tracking budgets.
- Should resolve the gradual coloring effect on category balances when opening the app.
- Minimal changes with no major issues or concerns.
These modifications effectively address the stated problem and should lead to a better user experience with faster initial rendering of goal-related information.
Also applies to: 262-263
🧰 Tools
🪛 GitHub Check: lint
[warning] 222-222:
Insert,
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
I think this will speed up the loading of the goal indicators on the budget page. I added the two cache entries to the list of values to prewarm for each month. This doesn't totally fix the issue, but I think it helps.
For a bit I've been seeing the category balances progressively color when opening the app(except for negative balances that are always colored correct). Sometimes it's really slow. It is more pronounced on mobile but still noticeable on desktop.