safe_image 0.1.3
safe_image: ^0.1.3 copied to clipboard
Safe image loading from URL with native downsampling. Prevents OOM crashes and UI jank with streaming download, disk caching, and concurrency control.
0.1.3 #
- Fix: invalidate old JPEG cache entries via cache key scheme version bump.
- Optimistic check now prefers PNG cache over JPEG for transparent images.
0.1.2 #
- Fix: stale JPEG cache no longer served for images with transparency.
- Restructured pipeline: alpha detection now happens before all cache key generation.
- Optimistic cache check now tries both JPEG and PNG variants.
0.1.1 #
- Fix: images with alpha channel (PNG/WebP) no longer lose transparency.
- Auto-detect alpha channel and encode as PNG instead of JPEG when transparency is present.
- Added
SafeImageFormat.pngoption. - Native code (Android/iOS) now respects the
formatparameter for PNG and WebP output.
0.1.0 #
- Initial public release.
- Streaming HTTP download with configurable timeouts and size limits.
- Native image downsampling on Android and iOS via MethodChannel.
- SHA-1 based disk caching with ETag support.
- Concurrency control via configurable semaphores.
SafeImageWidgetfor drop-in image loading.SafeImageScopefor sharing a single pipeline across the widget tree.- Automatic retry with reduced resolution on OOM/decode errors.