I have this
I want to pass this data
var pack = package.data;
And use it here
// Image.asset("assets/images/vip_1.png"),
Image.asset("....passed data....."),
I tried
Image.asset(pack.img),
but am getting null response.
Please help
You can do like this :
lib/assets/ -> add your images here
then utils.dart file :
var image1 = 'lib/assets/file_name.jpg';
now on your mainFile :
import your utils.dart file then
Image.asset(image1),