stable-hash
Advanced tools
Comparing version 0.0.3 to 0.0.4
@@ -1,1 +0,1 @@ | ||
var u=Object.defineProperty;var r=t=>u(t,"__esModule",{value:!0});var p=typeof require!="undefined"?require:t=>{throw new Error('Dynamic require of "'+t+'" is not supported')};var y=(t,i)=>{r(t);for(var s in i)u(t,s,{get:i[s],enumerable:!0})};y(exports,{default:()=>c});const o=new WeakMap;let b=0;function c(t){const i=typeof t,s=t&&t.constructor,f=s==Date;if(Object(t)===t&&!f&&s!=RegExp){let e=o.get(t);if(e)return e;e=++b+"~",o.set(t,e);let n;if(s==Array){for(e="@",n=0;n<t.length;n++)e+=c(t[n])+",";o.set(t,e)}else if(s==Object){e="#";const l=Object.keys(t).sort();for(;(n=l.pop())!==void 0;)t[n]!==void 0&&(e+=n+":"+c(t[n])+",");o.set(t,e)}return e}return f?t.toJSON():i=="symbol"?t.toString():i=="string"?JSON.stringify(t):""+t} | ||
var u=Object.defineProperty;var r=t=>u(t,"__esModule",{value:!0});var y=(t,i)=>{r(t);for(var s in i)u(t,s,{get:i[s],enumerable:!0})};y(exports,{default:()=>c});const o=new WeakMap;let b=0;function c(t){const i=typeof t,s=t&&t.constructor,f=s==Date;if(Object(t)===t&&!f&&s!=RegExp){let e=o.get(t);if(e)return e;e=++b+"~",o.set(t,e);let n;if(s==Array){for(e="@",n=0;n<t.length;n++)e+=c(t[n])+",";o.set(t,e)}else if(s==Object){e="#";const l=Object.keys(t).sort();for(;(n=l.pop())!==void 0;)t[n]!==void 0&&(e+=n+":"+c(t[n])+",");o.set(t,e)}return e}return f?t.toJSON():i=="symbol"?t.toString():i=="string"?JSON.stringify(t):""+t} |
{ | ||
"name": "stable-hash", | ||
"version": "0.0.3", | ||
"version": "0.0.4", | ||
"description": "Stable JS value hash.", | ||
@@ -13,3 +13,4 @@ "repository": "https://github.com/shuding/stable-hash", | ||
"require": "./dist/index.js", | ||
"import": "./dist/index.mjs" | ||
"import": "./dist/index.mjs", | ||
"types": "./dist/index.d.ts" | ||
}, | ||
@@ -19,9 +20,2 @@ "files": [ | ||
], | ||
"scripts": { | ||
"build:mjs": "esbuild src/index.ts --minify --target=es6 --outdir=dist --out-extension:.js=.mjs", | ||
"build:cjs": "esbuild src/index.ts --minify --target=es6 --outdir=dist --format=cjs", | ||
"build:types": "tsc --emitDeclarationOnly --declaration -p tsconfig.build.json", | ||
"build": "yarn build:mjs && yarn build:cjs && yarn build:types", | ||
"test": "jest" | ||
}, | ||
"devDependencies": { | ||
@@ -42,3 +36,10 @@ "@types/jest": "^28.1.3", | ||
"semi": false | ||
}, | ||
"scripts": { | ||
"build:mjs": "esbuild src/index.ts --minify --target=es6 --outdir=dist --out-extension:.js=.mjs", | ||
"build:cjs": "esbuild src/index.ts --minify --target=es6 --outdir=dist --format=cjs", | ||
"build:types": "tsc --emitDeclarationOnly --declaration -p tsconfig.build.json", | ||
"build": "yarn build:mjs && yarn build:cjs && yarn build:types", | ||
"test": "jest" | ||
} | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
2
1
5463