nl_tokens: Based on http : // werxltd . com / wp / 2010 / 05 / 13 / javascript - implementation - of - javas - string - hashcode - method /
pl_tokens: function createHash ( input ) { let hash = 0 ; if ( input . length === 0 ) { return hash ; } for ( let i = 0 ; i < input . length ; i ++ ) { const char = input . charCodeAt ( i ) ; hash = ( ( hash << 5 ) - <mask> ) + char ; // Convert to 32bit integer hash &= hash ; } return hash ; }