copyWith method
Creates a copy with updated fields.
Implementation
Reaction copyWith({
String? id,
String? emoji,
String? userId,
String? userName,
DateTime? createdAt,
}) {
return Reaction(
id: id ?? this.id,
emoji: emoji ?? this.emoji,
userId: userId ?? this.userId,
userName: userName ?? this.userName,
createdAt: createdAt ?? this.createdAt,
);
}