|
| 1 | +# Changelog |
| 2 | + |
| 3 | +All notable changes to this project will be documented in this file. |
| 4 | + |
| 5 | +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), |
| 6 | +and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). |
| 7 | + |
| 8 | +## [Unreleased] |
| 9 | + |
| 10 | +## [0.2.0] - 2025-01-08 |
| 11 | + |
| 12 | +### Added |
| 13 | +- **Infinite Query Support** - Complete implementation of infinite queries with pagination |
| 14 | + - `UseInfiniteQuery` SwiftUI component for infinite scrolling |
| 15 | + - `InfiniteQuery` core class for managing paginated data |
| 16 | + - `InfiniteQueryObserver` for reactive infinite query state management |
| 17 | + - Support for bidirectional pagination (next/previous pages) |
| 18 | + - Automatic page parameter calculation |
| 19 | + - Built-in pull-to-refresh support |
| 20 | +- **Configurable Initial Page** - Pokemon demo now supports starting from any offset |
| 21 | + - UI controls for selecting initial page |
| 22 | + - Automatic refresh when initial page changes |
| 23 | + - Proper cache separation for different starting points |
| 24 | +- **Enhanced SwiftUI Integration** |
| 25 | + - Fixed actor isolation issues for Swift 6 strict concurrency |
| 26 | + - Improved `onChange` handlers in `UseInfiniteQuery` |
| 27 | + - Better error handling and loading states |
| 28 | + |
| 29 | +### Changed |
| 30 | +- **Type Constraints** - Added `Equatable` constraint to `TPageParam` for proper change detection |
| 31 | +- **Options Handling** - Fixed issue where old options were used instead of current options |
| 32 | +- **Demo App** - Updated Pokemon list to showcase infinite query capabilities |
| 33 | + |
| 34 | +### Fixed |
| 35 | +- **Pull-to-Refresh Bug** - Fixed issue where first page was appended instead of resetting |
| 36 | +- **Actor Isolation** - Resolved Swift concurrency errors with `@State` properties in closures |
| 37 | +- **Query Key Changes** - Fixed `UseInfiniteQuery` to properly handle query key updates |
| 38 | + |
| 39 | +### Technical |
| 40 | +- Swift 6.0 compatible with strict concurrency mode |
| 41 | +- Comprehensive unit tests for infinite query functionality |
| 42 | +- Updated to use Perception library for iOS 16+ compatibility |
| 43 | +- Enhanced logging and debugging capabilities |
| 44 | + |
| 45 | +## [0.1.0] - 2024-12-XX |
| 46 | + |
| 47 | +### Added |
| 48 | +- Initial release of SwiftUI Query |
| 49 | +- **Core Query System** |
| 50 | + - `UseQuery` SwiftUI component for data fetching |
| 51 | + - `Query` class for individual query management |
| 52 | + - `QueryClient` for centralized query management |
| 53 | + - `QueryCache` with thread-safe operations |
| 54 | +- **SwiftUI Integration** |
| 55 | + - `QueryClientProvider` for dependency injection |
| 56 | + - Environment-based query client access |
| 57 | + - Reactive state updates with `@Perceptible` |
| 58 | +- **Advanced Features** |
| 59 | + - Automatic refetching (on mount, focus, reconnect) |
| 60 | + - Request deduplication and caching |
| 61 | + - Configurable retry logic with exponential backoff |
| 62 | + - Garbage collection for unused queries |
| 63 | + - Stale-while-revalidate caching strategy |
| 64 | +- **Developer Experience** |
| 65 | + - Comprehensive unit test suite |
| 66 | + - Swift 6 strict concurrency compliance |
| 67 | + - Multi-platform support (iOS, macOS, tvOS, watchOS) |
| 68 | + - Complete Pokemon API demo application |
| 69 | + |
| 70 | +[Unreleased]: https://github.com/muzix/swiftui-query/compare/v0.2.0...HEAD |
| 71 | +[0.2.0]: https://github.com/muzix/swiftui-query/compare/v0.1.0...v0.2.0 |
| 72 | +[0.1.0]: https://github.com/muzix/swiftui-query/releases/tag/v0.1.0 |
0 commit comments