Socket
Socket
Sign inDemoInstall

@sanity/util

Package Overview
Dependencies
Maintainers
47
Versions
1325
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sanity/util - npm Package Compare versions

Comparing version 3.36.4 to 3.36.5-canary.33

lib/client.d.mts

7

lib/concurrency-limiter.esm.js

@@ -0,6 +1,7 @@

var __defProp = Object.defineProperty, __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: !0, configurable: !0, writable: !0, value }) : obj[key] = value, __publicField = (obj, key, value) => (__defNormalProp(obj, typeof key != "symbol" ? key + "" : key, value), value);
class ConcurrencyLimiter {
constructor(max) {
this.max = max, this.current = 0, this.resolvers = [], this.ready = () => this.max === 1 / 0 ? Promise.resolve() : this.current < this.max ? (this.current++, Promise.resolve()) : new Promise((resolve) => {
this.max = max, __publicField(this, "current", 0), __publicField(this, "resolvers", []), __publicField(this, "ready", () => this.max === 1 / 0 ? Promise.resolve() : this.current < this.max ? (this.current++, Promise.resolve()) : new Promise((resolve) => {
this.resolvers.push(resolve);
}), this.release = () => {
})), __publicField(this, "release", () => {
if (this.max === 1 / 0)

@@ -14,3 +15,3 @@ return;

this.current = Math.max(0, this.current - 1);
};
});
}

@@ -17,0 +18,0 @@ }

"use strict";
Object.defineProperty(exports, "__esModule", { value: !0 });
var __defProp = Object.defineProperty, __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: !0, configurable: !0, writable: !0, value }) : obj[key] = value, __publicField = (obj, key, value) => (__defNormalProp(obj, typeof key != "symbol" ? key + "" : key, value), value);
class ConcurrencyLimiter {
constructor(max) {
this.max = max, this.current = 0, this.resolvers = [], this.ready = () => this.max === 1 / 0 ? Promise.resolve() : this.current < this.max ? (this.current++, Promise.resolve()) : new Promise((resolve) => {
this.max = max, __publicField(this, "current", 0), __publicField(this, "resolvers", []), __publicField(this, "ready", () => this.max === 1 / 0 ? Promise.resolve() : this.current < this.max ? (this.current++, Promise.resolve()) : new Promise((resolve) => {
this.resolvers.push(resolve);
}), this.release = () => {
})), __publicField(this, "release", () => {
if (this.max === 1 / 0)

@@ -16,3 +17,3 @@ return;

this.current = Math.max(0, this.current - 1);
};
});
}

@@ -19,0 +20,0 @@ }

{
"name": "@sanity/util",
"version": "3.36.4",
"version": "3.36.5-canary.33+f561374867",
"description": "Utilities shared across projects of Sanity",

@@ -24,90 +24,51 @@ "keywords": [

"author": "Sanity.io <hello@sanity.io>",
"sideEffects": false,
"exports": {
".": {
"types": "./lib/exports/index.d.ts",
"source": "./exports/index.ts",
"source": "./src/_exports/index.ts",
"import": "./lib/index.mjs",
"require": "./lib/index.js",
"node": {
"module": "./lib/index.esm.js",
"import": "./lib/index.cjs.mjs"
},
"import": "./lib/index.esm.js",
"default": "./lib/index.esm.js"
"default": "./lib/index.js"
},
"./fs": {
"types": "./lib/exports/fs.d.ts",
"source": "./exports/fs.ts",
"source": "./src/_exports/fs.ts",
"import": "./lib/fs.mjs",
"require": "./lib/fs.js",
"node": {
"module": "./lib/fs.esm.js",
"import": "./lib/fs.cjs.mjs"
},
"import": "./lib/fs.esm.js",
"default": "./lib/fs.esm.js"
"default": "./lib/fs.js"
},
"./client": {
"types": "./lib/exports/client.d.ts",
"source": "./exports/client.ts",
"source": "./src/_exports/client.ts",
"import": "./lib/client.mjs",
"require": "./lib/client.js",
"node": {
"module": "./lib/client.esm.js",
"import": "./lib/client.cjs.mjs"
},
"import": "./lib/client.esm.js",
"default": "./lib/client.esm.js"
"default": "./lib/client.js"
},
"./concurrency-limiter": {
"types": "./lib/exports/concurrency-limiter.d.ts",
"source": "./exports/concurrency-limiter.ts",
"source": "./src/_exports/concurrency-limiter.ts",
"import": "./lib/concurrency-limiter.mjs",
"require": "./lib/concurrency-limiter.js",
"node": {
"module": "./lib/concurrency-limiter.esm.js",
"import": "./lib/concurrency-limiter.cjs.mjs"
},
"import": "./lib/concurrency-limiter.esm.js",
"default": "./lib/concurrency-limiter.esm.js"
"default": "./lib/concurrency-limiter.js"
},
"./content": {
"types": "./lib/exports/content.d.ts",
"source": "./exports/content.ts",
"source": "./src/_exports/content.ts",
"import": "./lib/content.mjs",
"require": "./lib/content.js",
"node": {
"module": "./lib/content.esm.js",
"import": "./lib/content.cjs.mjs"
},
"import": "./lib/content.esm.js",
"default": "./lib/content.esm.js"
"default": "./lib/content.js"
},
"./createSafeJsonParser": {
"types": "./lib/exports/createSafeJsonParser.d.ts",
"source": "./exports/createSafeJsonParser.ts",
"source": "./src/_exports/createSafeJsonParser.ts",
"import": "./lib/createSafeJsonParser.mjs",
"require": "./lib/createSafeJsonParser.js",
"node": {
"module": "./lib/createSafeJsonParser.esm.js",
"import": "./lib/createSafeJsonParser.cjs.mjs"
},
"import": "./lib/createSafeJsonParser.esm.js",
"default": "./lib/createSafeJsonParser.esm.js"
"default": "./lib/createSafeJsonParser.js"
},
"./legacyDateFormat": {
"types": "./lib/exports/legacyDateFormat.d.ts",
"source": "./exports/legacyDateFormat.ts",
"source": "./src/_exports/legacyDateFormat.ts",
"import": "./lib/legacyDateFormat.mjs",
"require": "./lib/legacyDateFormat.js",
"node": {
"module": "./lib/legacyDateFormat.esm.js",
"import": "./lib/legacyDateFormat.cjs.mjs"
},
"import": "./lib/legacyDateFormat.esm.js",
"default": "./lib/legacyDateFormat.esm.js"
"default": "./lib/legacyDateFormat.js"
},
"./paths": {
"types": "./lib/exports/paths.d.ts",
"source": "./exports/paths.ts",
"source": "./src/_exports/paths.ts",
"import": "./lib/paths.mjs",
"require": "./lib/paths.js",
"node": {
"module": "./lib/paths.esm.js",
"import": "./lib/paths.cjs.mjs"
},
"import": "./lib/paths.esm.js",
"default": "./lib/paths.esm.js"
"default": "./lib/paths.js"
},

@@ -118,26 +79,26 @@ "./package.json": "./package.json"

"module": "./lib/index.esm.js",
"source": "./exports/index.ts",
"types": "./lib/exports/index.d.ts",
"source": "./src/_exports/index.ts",
"types": "./lib/index.d.ts",
"typesVersions": {
"*": {
"fs": [
"./lib/exports/fs.d.ts"
"./lib/fs.d.ts"
],
"client": [
"./lib/exports/client.d.ts"
"./lib/client.d.ts"
],
"concurrency-limiter": [
"./lib/exports/concurrency-limiter.d.ts"
"./lib/concurrency-limiter.d.ts"
],
"content": [
"./lib/exports/content.d.ts"
"./lib/content.d.ts"
],
"createSafeJsonParser": [
"./lib/exports/createSafeJsonParser.d.ts"
"./lib/createSafeJsonParser.d.ts"
],
"legacyDateFormat": [
"./lib/exports/legacyDateFormat.d.ts"
"./lib/legacyDateFormat.d.ts"
],
"paths": [
"./lib/exports/paths.d.ts"
"./lib/paths.d.ts"
]

@@ -147,2 +108,4 @@ }

"files": [
"lib",
"src",
"client.js",

@@ -154,18 +117,15 @@ "concurrency-limiter.js",

"legacyDateFormat.js",
"lib",
"paths.js",
"src"
"paths.js"
],
"scripts": {
"prebuild": "run-s clean",
"build": "pkg-utils build --tsconfig tsconfig.lib.json",
"postbuild": "run-s check:package",
"check:package": "pkg-utils --tsconfig tsconfig.lib.json",
"build": "run-s clean && pkg-utils build --strict",
"check:package": "pkg-utils --strict",
"check:types": "tsc",
"clean": "rimraf client.js concurrency-limiter.js content.js createSafeJsonParser.js fs.js legacyDateFormat.js lib paths.js",
"test": "jest",
"watch": "pkg-utils watch --tsconfig tsconfig.lib.json"
"watch": "pkg-utils watch"
},
"dependencies": {
"@sanity/client": "^6.15.7",
"@sanity/types": "3.36.4",
"@sanity/client": "^6.15.9",
"@sanity/types": "3.36.5-canary.33+f561374867",
"get-random-values-esm": "1.0.2",

@@ -177,2 +137,3 @@ "moment": "^2.29.4",

"@jest/globals": "^29.7.0",
"@repo/package.config": "0.0.0",
"@types/moment": "^2.13.0",

@@ -184,3 +145,3 @@ "rimraf": "^3.0.2"

},
"gitHead": "719f300471dc79a6b5c7aa3c0352fde537a78041"
"gitHead": "f561374867ae2f027f0b0c1bcd91bdd008413399"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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