I have Stored local images in assets/images file added the pubspcs.yml also
assets:
- Assets/images/ but i am fetching values from another dummy.dart file like this
return Scaffold(
backgroundColor: Colors.white,
appBar: AppBar(title: Text(categoryTitle)),
body: ListView.builder(
itemBuilder: (ctx, index) {
return MealItem(
id: displayedMeals[index].id,
title: displayedMeals[index].title,
**imageUrl: displayedMeals[index].imageUrl,**
duration: displayedMeals[index].duration,
affordability: displayedMeals[index].affordability,
complexity: displayedMeals[index].complexity,
// removeItem: _removeMeal,
);
/* Text(categoryMeals[index].title) */;
},
itemCount: displayedMeals.length,
)
);
and I want the image to come with this index file which i am fetching from dummy.dart
imageUrl:
'https://www.whiskaffair.com/wp-content/uploads/2018/02/Hyderabadi-Mutton-Biryani-6.jpg',
instead of this i want from the image from assets/images folder
MealItemMealItem:)