1 // DJB2 hash function
2 export function simpleHash(text: string): string {
3 let hash = 5381
4 for (let i = 0; i < text.length; i++) {
5 hash = (hash << 5) + hash + text.charCodeAt(i)
6 }
7 return hash.toString(16)
8 }