v0.2.0 — Enhanced DX, Validation & Critical Fixes
@grandgular/rive-angular v0.2.0
Major feature release with enhanced developer experience, comprehensive validation system, and critical stability improvements.
🎉 What's New
Debug Mode & Validation
- 🛠️ Debug Mode — New
debugModeinput andprovideRiveDebug()for configurable logging ('none' | 'error' | 'warn' | 'info' | 'debug') - ✅ Automatic Validation — Validates artboard, animation, state machine, and input names against loaded files with helpful suggestions
- 🏷️ Error Codes — Structured error codes (
RIVE_1xx,RIVE_2xx,RIVE_3xx) for programmatic error handling
Reactive Configuration
- ⚡ Reactive Inputs — All component inputs (
fit,alignment,artboard,animations,stateMachines) now trigger appropriate updates - 🎨 Layout Optimization — Changes to
fit/alignmentupdate layout without full reload
Architecture Improvements
- 🔒 Readonly Signals — Public signals properly encapsulated to prevent external mutation
- 🏗️ DI Integration —
ElementObserverconverted to Angular service for better testability - 📦 Type Safety — Eliminated unsafe type assertions in configuration
🐛 Critical Fixes
- 📱 Multi-Monitor Support — Device pixel ratio now read dynamically, supporting monitor changes and zoom
- ⏱️ Proper Timing —
riveReadyoutput now emits after animation fully loads (not just instance creation) - 🔄 Race Conditions — Fixed race conditions in
RiveFileServiceand cache management - 🧹 Memory Leaks — Fixed
clearCache()to properly handle pending loads - 🔐 No Mutations — Service no longer mutates
ArrayBufferobjects (usesWeakMap)
⚠️ Breaking Changes
1. Readonly Signals
Public signals (isPlaying, isPaused, isLoaded, riveInstance) are now readonly.
Before:
component.isPlaying.set(true); // ❌ No longer worksAfter:
component.playAnimation(); // ✅ Use component methods2. riveReady Timing
riveReady output now emits after animation is fully loaded.
Before:
// Emitted immediately, instance might not be ready
(riveReady)="onReady($event)"After:
// Emits after load, instance is guaranteed ready
(riveReady)="onReady($event)" // artboardNames available
// Or use (loaded) if you don't need the instance📚 Documentation
See CHANGELOG.md for complete details and migration guide.
🙏 Thanks
All 45 tests passing. Production-ready with comprehensive audit completed.