Pg lite - frontend db#1
Draft
krishna-404 wants to merge 3 commits into
Draft
Conversation
- add backend sync router with heartbeat SSE endpoint (15s interval) - create SSE manager in service worker with exponential backoff retry - replace OfflineBlocker with non-blocking OfflineBanner component - add SSE status badge to navbars showing connection state - reorganize service worker files into src/sw/ folder - add comlink dependency for main thread to SW communication - fix property naming: unit_size -> unitSize, validity_days -> validityDays - update signout utility to stop SSE monitoring on logout
- add auth.persistence.ts with localStorage-based session cache - implement fallback to cached session when offline or server unreachable - cache user info for welcome back UI on login page - add clear-cache mode to signout for intentional logout cleanup - update AGENTS.md with offline auth caching pattern documentation - mark offline-first feature as partial in DEVELOPMENT_PLAN.md
- add @electric-sql/pglite dependency for browser-based PostgreSQL - create web worker architecture with Comlink for DB operations - implement DBManager with IndexedDB persistence (idb:// protocol) - add journal_entries schema matching backend structure - create singleton proxy pattern with lazy initialization - add demo verification with SELECT 1 and INSERT/SELECT tests - configure vite for worker support and PGlite optimization - update DEVELOPMENT_PLAN.md and AGENTS.md with offline DB documentation
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.
Pg lite - frontend db