I write a program and ran it couple times to test the speed. I filled 60 number to a collection, the time for that is 10 to 15 seconds. That is too slow, are there any way to speed up?
my program is: let i=0; $w.onReady(function () { }); export function button1_click(event) { asyncloop(); } async function asyncloop() { for (var k = 0; k < 10; k++) { const j = 6; for ( i = 0; i < j; i++) { await getIndex(i); await mySave(i); $w("#text1").text= i.toString(); } } $w('#text1').text ="finished"; } function getIndex (x) { return $w("#dataset1").setCurrentItemIndex(x) .then( () => { } ); } function mySave (x) { $w("#dataset1").setFieldValue("timeOffset", x); return $w("#dataset1").save() .then( (item) => { } ); }