Skip to main content

offline_first_cache 0.1.1 copy "offline_first_cache: ^0.1.1" to clipboard
offline_first_cache: ^0.1.1 copied to clipboard

An offline-first HTTP client and caching engine for Flutter/Dart with request queuing, GET caching, dead-letter handling, and a Queue Inspector UI.

0.1.1 #

  • Dependency Constraints: Updated dio lower bound constraint to ^5.5.0 to ensure full compatibility with DioMediaType during dependency downgrade testing.

0.1.0 #

  • Drop-in UI Widgets:
    • Added OfflineBuilder: reactive widget rebuilding on connectivity and queue mutations.
    • Added SyncStatusBanner: animated status banner indicating offline mode, syncing progress, and online status.
    • Added QueueBadge: badged wrapper widget for action buttons (e.g. AppBar icons) showing pending sync count.
  • Offline Multipart & File Uploads:
    • Added OfflineFile and MultipartQueueHelper to queue file and media uploads taken offline.
    • Added postMultipart, putMultipart, and patchMultipart on OfflineHttpClient.
    • Streams files safely from disk on queue flush without database memory bloat.
  • HTTP Cache-Control Header Parsing:
    • Added CacheControl parser respecting max-age, s-maxage, stale-while-revalidate, no-store, no-cache, and Age response headers.
    • Configurable via respectCacheControlHeaders on OfflineClientConfig.
  • Static Analysis & Flutter 3.50+ Compatibility:
    • Suppressed deprecated member use on package:flutter/material.dart for future Flutter versions while maintaining backwards compatibility down to Flutter 3.24.0.
    • Closed cache storage box on client disposal.
    • Standardized code formatting across all files.

0.0.10 #

  • Package Metadata: Refined package description and pubspec metadata formatting.
  • Dependency Constraints: Updated Dio constraint lower bound (^5.4.0) and added compatibility support for flutter_secure_storage v11.

0.0.9 #

  • Structured Logging: Replaced console print calls in core interceptors with configurable OfflineLogger calls.
  • Dependency Optimization: Cleaned up unused transitive dependencies and updated package environment constraints.
  • Documentation: Fixed installation instructions and added package status badges in README.

0.0.8 #

  • Infinite Loop Fix (Stale-While-Revalidate): Fixed a critical bug where background revalidation requests re-entered the interceptor, causing an infinite GET loop on stale cache entries. Background revalidations are now flagged with _background_revalidate to bypass the cache-hit branch.
  • Concurrent Revalidation Deduplication: Background revalidations for the same URL are now deduplicated — multiple rapid GETs against a stale cache entry no longer fire redundant parallel network requests.
8
likes
160
points
176
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

An offline-first HTTP client and caching engine for Flutter/Dart with request queuing, GET caching, dead-letter handling, and a Queue Inspector UI.

Repository (GitHub)
View/report issues

License

MIT (license)

Dependencies

connectivity_plus, dio, flutter, flutter_secure_storage, hive, hive_flutter, uuid

More

Packages that depend on offline_first_cache