aboutsummaryrefslogtreecommitdiff
path: root/Timeline/ClientApp/src/app/utilities/language-untilities.ts
diff options
context:
space:
mode:
Diffstat (limited to 'Timeline/ClientApp/src/app/utilities/language-untilities.ts')
-rw-r--r--Timeline/ClientApp/src/app/utilities/language-untilities.ts6
1 files changed, 6 insertions, 0 deletions
diff --git a/Timeline/ClientApp/src/app/utilities/language-untilities.ts b/Timeline/ClientApp/src/app/utilities/language-untilities.ts
index 7f38f3e4..94434665 100644
--- a/Timeline/ClientApp/src/app/utilities/language-untilities.ts
+++ b/Timeline/ClientApp/src/app/utilities/language-untilities.ts
@@ -10,3 +10,9 @@ export function throwIfNullOrUndefined<T>(value: T | null | undefined,
return value;
}
}
+
+export function repeat(time: number, action: (index?: number) => void) {
+ for (let i = 0; i < time; i++) {
+ action(i);
+ }
+}