trackStateChange static method
Track state change (only called when enabled) Internal use only - called from Rx value setter
Implementation
static void trackStateChange(String id, dynamic oldValue, dynamic newValue) {
if (!_enabled || !_trackStateHistory) return;
_stateHistory.add(_StateSnapshot(
stateId: id,
oldValue: oldValue,
newValue: newValue,
timestamp: DateTime.now(),
));
_trimHistory();
}