build: switch from yarn to npm to manage js dependencies and move js contents to root
yarn v1 is being deprecated and starts to have some issues Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
10
src/utils/asyncForEach.ts
Normal file
10
src/utils/asyncForEach.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
async function asyncForEach(
|
||||
array: Array<any>,
|
||||
callback: (arg0: any, arg1: number, arg2: Array<any>) => void
|
||||
): Promise<void> {
|
||||
for (let index = 0; index < array.length; index += 1) {
|
||||
callback(array[index], index, array);
|
||||
}
|
||||
}
|
||||
|
||||
export { asyncForEach };
|
||||
Reference in New Issue
Block a user