Product constructor

const Product({
  1. required String id,
  2. required double price,
  3. String? name,
  4. bool? isAvailable,
  5. List<String> images = const ['madagascar', 'paris', 'newyork'],
  6. int? max = 0,
  7. Status? status = Status.activeFile,
  8. String? description,
  9. List<int> counts = const [1, 2, 3],
  10. DateTime? createdAt,
})

Implementation

const Product({
  required this.id,
  required this.price,
 this.name,
 this.isAvailable,
  this.images = const ['madagascar','paris','newyork'],
  this.max = 0,
  this.status = Status.activeFile,
 this.description,
  this.counts = const [1, 2, 3],
   this.createdAt,
});