copyWith method
NiceNestableItem<T>
copyWith({
- String? id,
- T? data,
- List<
NiceNestableItem< ? children,T> > - bool? expanded,
Implementation
NiceNestableItem<T> copyWith({
String? id,
T? data,
List<NiceNestableItem<T>>? children,
bool? expanded,
}) {
return NiceNestableItem<T>(
id: id ?? this.id,
data: data ?? this.data,
children: children ?? this.children,
expanded: expanded ?? this.expanded,
);
}