github.com/argoproj/argo-cd@v1.8.7/ui/src/app/shared/utils.ts (about)

     1  export function hashCode(str: string) {
     2      let hash = 0;
     3      for (let i = 0; i < str.length; i++) {
     4          // tslint:disable-next-line:no-bitwise
     5          hash = ~~((hash << 5) - hash + str.charCodeAt(i));
     6      }
     7      return hash;
     8  }