TimelineModel.fromMap constructor
Creates a TimelineModel from a Map (typically from native platform)
Implementation
factory TimelineModel.fromMap(Map<String, dynamic> map) {
return TimelineModel(
stepCount: (map['step_count'] as num?)?.toInt() ?? 0,
timestamp: (map['timestamp'] as num?)?.toInt() ?? 0,
);
}