Skip to content

Tauri Plugin Cache v0.1.6: Native iOS Compression & Bun Support

Latest

Choose a tag to compare

@Taiizor Taiizor released this 09 Dec 04:25
· 6 commits to develop since this release

🚀 Tauri Plugin Cache v0.1.6

This release migrates iOS compression to Apple's native Compression framework, adds Bun package manager support, and introduces improved error handling with API enhancements.

✨ New Features

  • Native iOS Compression: Apple's Compression framework integration for better performance
  • Bun Package Manager Support: Faster builds with Bun support across the project
  • Enhanced Error Handling: New CachePluginError enum for better error management
  • Flexible JSON Values: set method now supports arbitrary JSON values
  • Optional Value Responses: New OptionalValueResponse for nullable cache entries
  • Default Compression Method: CompressionMethod enum now has default value support

🔍 Technical Details

  • iOS Compression Rewrite: Migrated from PLzmaSDK to Apple's native Compression framework
  • Tauri SDK Updates: Updated to Tauri 2.9.4 and tauri-plugin 2.5.2
  • Improved Mobile Init: Refactored iOS plugin initialization in mobile.rs
  • Android Error Import: Fixed Error import for Android target compilation
  • CI/CD Enhancements: New multi-platform build workflow with JS API integration
  • Dependency Cleanup: Removed lock files from repository for cleaner dependency management

🧰 Features

  • Type Safety: Full TypeScript typings
  • Cache Statistics: Monitor cache usage
  • Optional TTL: Set expiration times for cache items
  • Disk-based Cache: Persistent data storage and retrieval
  • Data Compression: Enable compression for large data items
  • Cross-Platform: Works on desktop and mobile (Android and iOS)
  • Memory Caching: In-memory caching layer for improved performance
  • Performance Optimized: Buffered I/O and chunked processing for large datasets
  • Multiple Compression Methods: Choose between Zlib (fast) and LZMA2 (high ratio) on all platforms

🚀 Getting Started

# Rust
cargo add tauri-plugin-cache@0.1.6

# JavaScript/TypeScript
bun add tauri-plugin-cache-api@0.1.6
# or
npm install tauri-plugin-cache-api@0.1.6

For documentation and examples, please refer to the README.md file.

What's Changed

  • Migrated iOS compression to Apple's native Compression framework
  • Added Bun package manager support with updated build scripts
  • Introduced CachePluginError enum for improved error handling
  • Refactored set method to support arbitrary JSON values
  • Added OptionalValueResponse for optional cache value returns
  • Fixed iOS plugin initialization in mobile.rs
  • Added Error import for Android target in mobile.rs
  • Updated to Tauri 2.9.4 and tauri-plugin 2.5.2
  • Added comprehensive multi-platform CI build workflow
  • Updated dependencies: flate2, rollup, typescript, and @tauri-apps/api
  • Cleaned up lock files and updated .gitignore

📦 Dependency Updates

Package Previous Current
tauri 2.5.1 2.9.4
tauri-plugin 2.2.0 2.5.2
@tauri-apps/api ^2.5.0 ^2.9.1
flate2 1.1.1 1.1.2
rollup ^4.34.8 ^4.53.3
typescript ^5.7.3 ^5.9.3

Full Changelog: v0.1.5...v0.1.6