epic: first try at adding a backend

This commit is contained in:
2023-10-27 12:14:12 +02:00
parent 0a5c6c5618
commit 9a5b467ab0
114 changed files with 2167 additions and 35 deletions
+6
View File
@@ -0,0 +1,6 @@
export function arraySetN<T>(array: T[], n: number, elem: T): T[] {
if (array.length < n || n < 0) {
return array
}
return [...array.slice(0, n), elem, ...array.slice(n+1)]
}