Generate copy
extension for class that annotated with @copy
from copy_annotation.
Installation
dev_dependencies:
...
build_runner: ^latest_version
copy_annotation_gen: ^latest_version
Usage
part 'employee.g.dart'
@copy
class Employee {
final int id;
final String name;
Employee({required this.id,required this.name})
}
and run
flutter pub run build_runner build --delete-conflicting-outputs