toJson method Null safety
Implementation
Map<String, dynamic> toJson() => {
"id": id,
"name": name,
"title": title,
"hexa": hexa,
"isOutOfStock": isOutOfStock,
};
Map<String, dynamic> toJson() => {
"id": id,
"name": name,
"title": title,
"hexa": hexa,
"isOutOfStock": isOutOfStock,
};