copyWith method

DashboardStat copyWith({
  1. IconData? icon,
  2. String? title,
  3. String? count,
})

Returns a copy of this DashboardStat with optional new values for its fields.

If a parameter is not provided, the current value is used.

Implementation

DashboardStat copyWith({IconData? icon, String? title, String? count}) {
  return DashboardStat(
    icon: icon ?? this.icon,
    title: title ?? this.title,
    count: count ?? this.count,
  );
}