Socket
Socket
Sign inDemoInstall

@emotion/hash

Package Overview
Dependencies
Maintainers
2
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@emotion/hash - npm Package Compare versions

Comparing version 0.6.6 to 0.7.0

dist/hash.browser.cjs.js

40

dist/hash.cjs.js
'use strict';
/* eslint-disable */
// murmurhash2 via https://github.com/garycourt/murmurhash-js/blob/master/murmurhash2_gc.js
function murmurhash2_32_gc(str) {
var l = str.length,
h = l ^ l,
i = 0,
k;
while (l >= 4) {
k = str.charCodeAt(i) & 0xff | (str.charCodeAt(++i) & 0xff) << 8 | (str.charCodeAt(++i) & 0xff) << 16 | (str.charCodeAt(++i) & 0xff) << 24;
k = (k & 0xffff) * 0x5bd1e995 + (((k >>> 16) * 0x5bd1e995 & 0xffff) << 16);
k ^= k >>> 24;
k = (k & 0xffff) * 0x5bd1e995 + (((k >>> 16) * 0x5bd1e995 & 0xffff) << 16);
h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16) ^ k;
l -= 4;
++i;
}
switch (l) {
case 3:
h ^= (str.charCodeAt(i + 2) & 0xff) << 16;
case 2:
h ^= (str.charCodeAt(i + 1) & 0xff) << 8;
case 1:
h ^= str.charCodeAt(i) & 0xff;
h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16);
}
h ^= h >>> 13;
h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16);
h ^= h >>> 15;
return (h >>> 0).toString(36);
if (process.env.NODE_ENV === 'production') {
module.exports = require('./hash.cjs.prod.js');
} else {
module.exports = require('./hash.cjs.dev.js');
}
module.exports = murmurhash2_32_gc;
{
"name": "@emotion/hash",
"version": "0.6.6",
"version": "0.7.0",
"description": "A MurmurHash2 implementation",

@@ -8,3 +8,3 @@ "main": "dist/hash.cjs.js",

"license": "MIT",
"repository": "https://github.com/emotion-js/emotion/tree/master/next-packages/hash",
"repository": "https://github.com/emotion-js/emotion/tree/master/packages/hash",
"publishConfig": {

@@ -18,3 +18,6 @@ "access": "public"

"umd:main": "./dist/index.min.js",
"gitHead": "94fed7652759a0f1962da66b922299398e39fe4d"
"browser": {
"./dist/hash.cjs.js": "./dist/hash.browser.cjs.js",
"./dist/hash.esm.js": "./dist/hash.browser.esm.js"
}
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc