Proof of concept dynamic tile loading 2

This commit is contained in:
2024-10-27 18:48:19 +01:00
parent 446e049e6e
commit 4f8517a50c
7 changed files with 30 additions and 16 deletions

View File

@ -1,3 +1,7 @@
export function uuidv4() {
return '10000000-1000-4000-8000-100000000000'.replace(/[018]/g, (c) => (+c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (+c / 4)))).toString(16))
}
export function unduplicateArray(array: any[]) {
return [...new Set(array.flat())]
}