v3.1.0 #12
ImonChakraborty
announced in
Announcements
v3.1.0
#12
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Major Changes - Local-First Architecture Migration
Architecture Redesign
lib/syncEngine.ts) now the single source of truth for all Appwrite database communicationlib/syncEngine.tscan calldatabases.*methodsNew Components
reloadFromLocal()added to all 4 data contexts (WatchlistContext, WatchHistoryContext, ReadlistContext, ReadHistoryContext) for state refresh without triggering cloud callsContext Refactoring
refreshWatchlist()Data Sync Behavior
syncCollection()callsAppwrite Usage Reduction
Code Quality Improvements
{ ID } from 'appwrite'import fromstreaming.tsx— replaced with local UUID generatorcleanupDuplicateDocuments()call in streaming player initializationstreaming.tsx,manga-reader.tsx, explore, watchlist, readlist, etc.) now exclusively interact with contexts (no Appwrite imports except for auth)Added
reloadFromLocal()method on all 4 data contextsSyncEngine.shouldAutoSync()— checks 24-hour intervalSyncEngine.bootstrapFromCloud()— pulls all data on first login/new deviceSyncEngine.performFullSync()— bidirectional sync of all collectionsSyncEngine.syncCollection()— single collection sync for manual sync buttonsChanged
refreshWatchlist()now syncs with cloud before reloading staterefreshWatchHistory()andsyncHistory()use SyncEngine instead of direct cloud callsrefreshReadlist()delegates to SyncEnginerefreshHistory()uses SyncEngine for manual syncID.unique()with local timestamp-based UUID generatoruseWatchlist/useWatchHistoryimports from GlobalProviderRemoved
cleanupDuplicateDocuments()call from streaming player (handled by SyncEngine now)streaming.tsxFixed
reloadFromLocal()methodPerformance Impact
Migration Notes
Technical Details
@kaizen_local_watchlist,@kaizen_local_watchhistory,@kaizen_local_readlist,@kaizen_local_readhistory24 * 60 * 60 * 1000(86,400,000ms)upsert(create/update),deleteThis discussion was created from the release v3.1.0.
Beta Was this translation helpful? Give feedback.
All reactions