Devyimageloader not caching image

i am using dynamic components by extension in my app i used a card view in and a image in that card view i have used devybimageloader extension to cache image but after install and used app it is not caching image i checked the cache folder of that app in android it is empty probably i am making a mistake or i have missed something plz correct me here are the blocks and also( give your suggestion which image loader is best to use with dynamic components by kodular and dynamic components extension) thanks

I thinks the problem is Card View it don’t support what you want to set, you can’t set an image.
Card View only support Background Color. For this reason the extension don’t show you the images.
Take a look at Card View the documentation

To solve this you can insert dynamically a button inside the card view. Button support background image.
Look at these blocks. I used number + 100 for Button ID ( not to duplicate the ID)

I hope this help you.

1 Like

Mean i have to use a button ok but what will +100 do can u plz guide me

Yes i suggest created a button inside the each card view.
You can set the same size to button to fill the card view.
“+ 100” is used to not duplicate the ID, this way you can create a maximum of 99 card view, if you need more change 100 to 200 or value you need.
How work + 100:
When Number = 1 created a card view with ID = 1 and created a button Number + 100 button ID = 101
When Number = 2 created a crad view with ID = 2 and created a button Number + 100 button ID = 102
so successively, I hope you understand me.

You may use the ‘ExtractCachedImage’ block.
saveIn: The cache file directory.
This method works only if WRITE_EXTERNAL_STORAGE is granted before loading/caching the image.
So you have to ask for permission first.2d686e367e86aee653896b61d9283f1b01074d8c_2_690x252
[Image taken from DebYbImageLoader’s extensions post.]

Then use the block ‘OnExtractCacheImage’ and store the ‘path’ value into a variable.

Hope this may help you.

1 Like