angular - IONIC - VirtualScroll Performance issue -


so, have array of items between 0 - 2500.

i'm trying use virtualscroll option (as have read handle large arrays) improve diabolical performance issue when displaying\scrolling through 1300 items.

so i've done following, still painful , can crash app when scrolling.

 <ion-list [virtualscroll]="results" approxitemwidth="100%" approxitemheight="45px" bufferratio=60>     <button ion-item   *virtualitem="let result" (click)="gotoclient(result)">       {{result.firstname}} {{result.lastname}}     </button>   </ion-list>  

anyone advise i'm doing wrong\ how improve?

try install cordova wkwebview engine , optimizes ios performance issues:

installation instructions

ensure latest cordova cli installed: (sudo may required)

npm install cordova -g 

ensure ios platform has been added:

ionic cordova platform ls 

if ios platform not listed, run following command:

ionic cordova platform add ios 

if ios platform installed version < 4.x, run following commands:

ionic cordova platform update ios ionic cordova plugin save           # creates backup of existing plugins rm -rf ./plugins            # delete plugins directory ionic cordova prepare               # re-install plugins compatible cordova-ios 4.x 

install wkwebviewplugin:

ionic cordova plugin add https://github.com/ionic-team/cordova-plugin-wkwebview-engine.git --save 

note:

if had apache/cordova-plugin-wkwebview-engine install make sure removed before using version.

ionic cordova plugin rm cordova-plugin-wkwebview-engine 

build platform:

ionic cordova prepare 

test app on ios 9 or 10 device:

ionic cordova run ios 

an easy way verify wkwebview has been installed on ios check if window.indexeddb exists. example:

if (window.indexeddb) {    console.log("i'm in wkwebview!"); } else {    console.log("i'm in uiwebview"); } 

required permissions

wkwebview may not launch (the deviceready event may not fire) unless if following included in config.xml:

config.xml

<allow-navigation href="http://localhost:8080/*"/> <feature name="cdvwkwebviewengine">   <param name="ios-package" value="cdvwkwebviewengine" /> </feature>  <preference name="cordovawebviewengine" value="cdvwkwebviewengine" /> 

here find complete instructions


Comments

Popular posts from this blog

python Tkinter Capturing keyboard events save as one single string -

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

javascript - Z-index in d3.js -