- Windows 10 Build 18917+ (only as Windows Insider 09/2019)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const updatedCollection = []; | |
const originalCollection = [1,2,3,4,5]; | |
const pushAsync = (collection, value) => { | |
return new Promise((resolve) => { | |
setTimeout(() => { | |
console.log(`Multiplying value: ${value} and inserting it into the updated collection`); | |
collection.push(value * 2); | |
resolve(); | |
}, value); |