copy_annotation

Creator: coderz1093

Last updated:

0 purchases

copy_annotation Image
copy_annotation Images

Languages

Categories

Add to Cart

Description:

copy annotation

"copy_annotation" is a annotation based code generation package for Flutter that generates a copyWith method with extension functions for immutable classes.
Work together with copy_annotation_gen to generate code.
Usage #
dependencies:
copy_annotation: ^latest_version
copied to clipboard
Then, you need to add the following dependencies for code generation:
dev_dependencies:
build_runner: ^latest_version
copy_annotation_gen: ^latest_version

copied to clipboard
Example #

@copy
class Employee {
final int id;
final String name;

Employee({required this.id,required this.name})

}


final emp1 = Employee(id:1,name:"John");
final emp2 = emp1.copy(id:2,name:"Mina");
copied to clipboard

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.