Ionic - scrollable list of large images - memory usage

I have an Ionic app that uses the latest versions of angular 4 and ionic 3.

The application contains a scrollable list of many fairly large images.

I had a memory failure on iOS due to the fact that all the huge textures accumulate in memory.

Now I am using VirtualScroll and ion image to try to solve this problem.

I also plan to use wkwebview.

Can any of these descriptors unload textures from memory if they are not in the viewport?

If not, how do I do this manually?

+4
source share
1

VirtualScroll:

, DOM , , DOM .

VirtualScroll . DOM , 1000 , .

ion-img :

ion-img img, . , , - HTTP-, .

:

ion-img

, , , .

:

ion-img cache

, , . VirtualScroll, , , , , .

.

, , -, , -, .

:

https://ionicframework.com/docs/api/components/img/Img/, https://ionicframework.com/docs/api/components/virtual-scroll/VirtualScroll/, https://www.joshmorony.com/boosting-scroll-performance-in-ionic-2/

+2

Source: https://habr.com/ru/post/1680258/


All Articles