V2.0#10
Conversation
There was a problem hiding this comment.
Pull request overview
This pull request introduces version 2.0.0 of Smart Reference, a significant update that adds asset lifecycle management, expanded async support, and improved documentation. The update transforms Smart Reference from a simple lazy-loading solution into a more complete asset management system with release capabilities and multiple async patterns.
Key Changes:
- Added asset release API with Cancel support for managing asset lifecycle and memory
- Implemented UniTask support alongside existing Task-based async for performance-critical scenarios
- Introduced handle-based architecture (ISmartReferenceHandle, ResourcesHandle, AddressablesHandle) to track loading operations
- Added comprehensive test suites (PlayModeTests and EditModeTests) with 400+ lines of test coverage
- Expanded documentation with dedicated manual pages for initialization, loading patterns, releasing, and custom loaders
Reviewed changes
Copilot reviewed 57 out of 57 changed files in this pull request and generated 20 comments.
Show a summary per file
| File | Description |
|---|---|
| package.json | Version bump to 2.0.0, updated description emphasizing memory optimization, added author URL and new keywords |
| Runtime/SmartReference.cs | Core implementation with new async methods (LoadAsyncTask, LoadAsyncUniTask), Release/Cancel logic, event-based callbacks, and handle management |
| Runtime/SmartReference.Runtime.asmdef | Updated assembly references to use package names instead of GUIDs, added UniTask reference and version defines |
| Runtime/Loaders/ISmartReferenceLoader.cs | Extended interface with Release and Cancel methods, added comprehensive documentation for each method |
| Runtime/Loaders/ResourcesLoader.cs | Implemented Release/Cancel methods, improved path parsing with better edge case handling |
| Runtime/Loaders/AddressablesLoader.cs | Added Release/Cancel implementations, WebGL synchronous load error handling |
| Runtime/Loaders/CustomLoader.cs | Removed deprecated delegate-based custom loader in favor of ISmartReferenceLoader interface |
| Runtime/Handles/*.cs | New handle system files (ISmartReferenceHandle, ResourcesHandle, AddressablesHandle) for tracking load operations |
| Editor/SmartReferenceEditor.cs | Refactored to use SmartReferenceTool for cleaner separation of concerns |
| Editor/SmartReferenceTool.cs | New utility for programmatically setting/clearing references with validation |
| Tests/Runtime/PlayModeTests.cs | Comprehensive runtime tests covering sync/async loading, in-flight sharing, release semantics, and performance |
| Tests/Runtime/EditModeTests.cs | Editor-focused tests for SmartReferenceTool validation and serialization behavior |
| Tests/Runtime/AssetSetup.cs | Test infrastructure for creating temporary test assets in Resources folders |
| Tools~/DocFx/docs/*.md | New manual documentation pages explaining initialization, synchronous/asynchronous loading, releasing assets, and custom loaders |
| Tools~/DocFx/index.md | Updated quick start guide with modern async patterns and version badges |
| Tools~/DocFx/docfx.json | Updated build configuration for .NET 8, added docs folder, commented out PDF generation |
| .github/workflows/docfx-build-publish.yml | Updated to GitHub Actions v6/v7, .NET 8, added test deployment workflow |
| README.md | Rewritten with clearer structure showing initialization options and multiple loading patterns |
| CHANGELOG.md | Added 2.0.0 release notes documenting new features |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 57 out of 57 changed files in this pull request and generated 13 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
No description provided.