Paint the board instantly instead of showing a loading screen#80
Merged
Conversation
Drop the 'Opening Dayboard' loading view. New tabs no longer block on the async chrome.storage.sync read: the board is mirrored into localStorage and the first render hydrates synchronously from it, with the authoritative sync read reconciling afterward. Load-time entrance animations are gone too; the card-enter animation now only plays for cards that appear while the board is already on screen.
91383d4 to
0567d1f
Compare
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.
Summary
chrome.storage.sync, so the board is in the very first paint; the authoritative sync read reconciles afterward and keeps the mirror fresh on every read/write/sync changecard-enternow only plays for cards that appear while the board is already on screen (added/restored); the empty state no longer animates eitherTrade-off
If the board changed on another device since this machine last saw it, the last-known board shows briefly before the synced version swaps in (stale-while-revalidate) — preferable to a blank frame or spinner on every tab open.
Testing
npm run typecheckclean