foxts 5.5.1 → 5.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- "use strict";var t=require("../abort-error/index.js"),e=require("../extract-error-message/index.js"),r=require("../is-network-error/index.js"),o=require("../noop/index.js"),i=require("../wait/index.js");const{round:n}=Math,a=Error,s=TypeError;function c(t,e,r=0,o=!1){if(Number.isNaN(e))throw new s(`Expected \`${t}\` to be a valid number${o?" or Infinity":""}, got NaN.`);if(!o&&!Number.isFinite(e))throw new s(`Expected \`${t}\` to be a finite number.`);if(e<r)throw new s(`Expected \`${t}\` to be \u2265 ${r}.`)}class u extends a{name="AsyncRetryAbortError";cause;constructor(t){if(super("string"==typeof t?t:e.extractErrorMessage(t,!1)??"Aborted"),"string"==typeof t){const e=new a(t);e.stack=this.stack,this.cause=e}else t instanceof a?(this.cause=t,this.message=t.message):this.cause=t}}async function m(e,o,a,c,m){if(e instanceof u)throw e.cause;if(e instanceof s&&!r.isNetworkError(e)||t.isAbortErrorLike(e))throw e;const f=a.retries-(o-1),w={error:e,attemptNumber:o,retriesLeft:f};await a.onFailedAttempt(w),o>1&&await a.onRetry(e,o-1);const h=Date.now();if(h-c>=m||o>=a.retries+1||!await a.shouldRetry(w))throw e;let d=n((a.randomize?Math.random()+1:1)*a.minTimeout*a.factor**(o-1));d>a.maxTimeout&&(d=a.maxTimeout);const b=m-(h-c);if(b<=0)throw e;let x=d;d>b&&(x=b),x>0&&await i.waitWithAbort(x,a.signal,a.unref),a.signal?.throwIfAborted()}function f(t){throw new u(t??"Aborted")}async function w(t,e={}){e.signal?.throwIfAborted();const r={...e};r.retries??=10,r.forever??=!1,r.factor??=2,r.minTimeout??=1e3,r.maxTimeout??=1/0,r.randomize??=!0,r.onFailedAttempt??=o.noop,r.onRetry??=o.noop,r.shouldRetry??=o.trueFn,r.forever&&(r.retries=1/0),c("retries",r.retries,0,!0),c("factor",r.factor,0,!1),c("minTimeout",r.minTimeout,0,!1),c("maxTimeout",r.maxTimeout,0,!0);const i=r.maxRetryTime??1/0;c("maxRetryTime",i,0,!0),r.minTimeout<1&&(r.minTimeout=1),r.factor<=0&&(r.factor=1);let n=0;const s=Date.now();for(;n<r.retries+1;){n++;try{r.signal?.throwIfAborted();const e=await t(f,n);return r.signal?.throwIfAborted(),e}catch(e){let t=e;"object"==typeof e&&e&&"bail"in e&&e.bail&&(t=new u(e)),await m(t,n,r,s,i)}}throw new a("Retry attempts exhausted without throwing an error.")}exports.AsyncRetryAbortError=u,exports.asyncRetry=w,exports.makeRetriable=function(t,e){return function(...r){return w(()=>t.apply(this,r),e)}};
1
+ "use strict";var e=require("../abort-error/index.js"),t=require("../extract-error-message/index.js"),r=require("../is-network-error/index.js"),o=require("../noop/index.js"),i=require("../wait/index.js");const{round:n}=Math,a=Error,s=TypeError;function c(e,t,r=0,o=!1){if(Number.isNaN(t))throw new s(`Expected \`${e}\` to be a valid number${o?" or Infinity":""}, got NaN.`);if(!o&&!Number.isFinite(t))throw new s(`Expected \`${e}\` to be a finite number.`);if(t<r)throw new s(`Expected \`${e}\` to be \u{2265} ${r}.`)}class u extends a{name="AsyncRetryAbortError";cause;constructor(e){if(super("string"==typeof e?e:t.extractErrorMessage(e,!1)??"Aborted"),"string"==typeof e){const t=new a(e);t.stack=this.stack,this.cause=t}else t.isErrorLikeObject(e)?(this.cause=e,this.message=e.message):this.cause=e}}async function m(t,o,a,c,m){if(t instanceof u)throw t.cause;if(t instanceof s&&!r.isNetworkError(t)||e.isAbortErrorLike(t))throw t;const f=a.retries-(o-1),w={error:t,attemptNumber:o,retriesLeft:f};await a.onFailedAttempt(w),o>1&&await a.onRetry(t,o-1);const h=Date.now();if(h-c>=m||o>=a.retries+1||!await a.shouldRetry(w))throw t;let d=n((a.randomize?Math.random()+1:1)*a.minTimeout*a.factor**(o-1));d>a.maxTimeout&&(d=a.maxTimeout);const b=m-(h-c);if(b<=0)throw t;let x=d;d>b&&(x=b),x>0&&await i.waitWithAbort(x,a.signal,a.unref),a.signal?.throwIfAborted()}function f(e){throw new u(e??"Aborted")}async function w(e,t={}){t.signal?.throwIfAborted();const r={...t};r.retries??=10,r.forever??=!1,r.factor??=2,r.minTimeout??=1e3,r.maxTimeout??=1/0,r.randomize??=!0,r.onFailedAttempt??=o.noop,r.onRetry??=o.noop,r.shouldRetry??=o.trueFn,r.forever&&(r.retries=1/0),c("retries",r.retries,0,!0),c("factor",r.factor,0,!1),c("minTimeout",r.minTimeout,0,!1),c("maxTimeout",r.maxTimeout,0,!0);const i=r.maxRetryTime??1/0;c("maxRetryTime",i,0,!0),r.minTimeout<1&&(r.minTimeout=1),r.factor<=0&&(r.factor=1);let n=0;const s=Date.now();for(;n<r.retries+1;){n++;try{r.signal?.throwIfAborted();const t=await e(f,n);return r.signal?.throwIfAborted(),t}catch(t){let e=t;"object"==typeof t&&t&&"bail"in t&&t.bail&&(e=new u(t)),await m(e,n,r,s,i)}}throw new a("Retry attempts exhausted without throwing an error.")}exports.AsyncRetryAbortError=u,exports.asyncRetry=w,exports.makeRetriable=function(e,t){return function(...r){return w(()=>e.apply(this,r),t)}};
@@ -1 +1 @@
1
- import{isAbortErrorLike as t}from"../abort-error/index.mjs";import{extractErrorMessage as e}from"../extract-error-message/index.mjs";import{isNetworkError as r}from"../is-network-error/index.mjs";import{noop as o,trueFn as i}from"../noop/index.mjs";import{waitWithAbort as n}from"../wait/index.mjs";const{round:a}=Math,s=Error,m=TypeError;function c(t,e,r=0,o=!1){if(Number.isNaN(e))throw new m(`Expected \`${t}\` to be a valid number${o?" or Infinity":""}, got NaN.`);if(!o&&!Number.isFinite(e))throw new m(`Expected \`${t}\` to be a finite number.`);if(e<r)throw new m(`Expected \`${t}\` to be \u2265 ${r}.`)}class f extends s{name="AsyncRetryAbortError";cause;constructor(t){if(super("string"==typeof t?t:e(t,!1)??"Aborted"),"string"==typeof t){const e=new s(t);e.stack=this.stack,this.cause=e}else t instanceof s?(this.cause=t,this.message=t.message):this.cause=t}}async function u(e,o,i,s,c){if(e instanceof f)throw e.cause;if(e instanceof m&&!r(e)||t(e))throw e;const u=i.retries-(o-1),w={error:e,attemptNumber:o,retriesLeft:u};await i.onFailedAttempt(w),o>1&&await i.onRetry(e,o-1);const h=Date.now();if(h-s>=c||o>=i.retries+1||!await i.shouldRetry(w))throw e;let d=a((i.randomize?Math.random()+1:1)*i.minTimeout*i.factor**(o-1));d>i.maxTimeout&&(d=i.maxTimeout);const y=c-(h-s);if(y<=0)throw e;let b=d;d>y&&(b=y),b>0&&await n(b,i.signal,i.unref),i.signal?.throwIfAborted()}function w(t){throw new f(t??"Aborted")}async function h(t,e={}){e.signal?.throwIfAborted();const r={...e};r.retries??=10,r.forever??=!1,r.factor??=2,r.minTimeout??=1e3,r.maxTimeout??=1/0,r.randomize??=!0,r.onFailedAttempt??=o,r.onRetry??=o,r.shouldRetry??=i,r.forever&&(r.retries=1/0),c("retries",r.retries,0,!0),c("factor",r.factor,0,!1),c("minTimeout",r.minTimeout,0,!1),c("maxTimeout",r.maxTimeout,0,!0);const n=r.maxRetryTime??1/0;c("maxRetryTime",n,0,!0),r.minTimeout<1&&(r.minTimeout=1),r.factor<=0&&(r.factor=1);let a=0;const m=Date.now();for(;a<r.retries+1;){a++;try{r.signal?.throwIfAborted();const e=await t(w,a);return r.signal?.throwIfAborted(),e}catch(e){let t=e;"object"==typeof e&&e&&"bail"in e&&e.bail&&(t=new f(e)),await u(t,a,r,m,n)}}throw new s("Retry attempts exhausted without throwing an error.")}function d(t,e){return function(...r){return h(()=>t.apply(this,r),e)}}export{f as AsyncRetryAbortError,h as asyncRetry,d as makeRetriable};
1
+ import{isAbortErrorLike as t}from"../abort-error/index.mjs";import{extractErrorMessage as e,isErrorLikeObject as r}from"../extract-error-message/index.mjs";import{isNetworkError as o}from"../is-network-error/index.mjs";import{noop as i,trueFn as n}from"../noop/index.mjs";import{waitWithAbort as a}from"../wait/index.mjs";const{round:s}=Math,m=Error,c=TypeError;function f(t,e,r=0,o=!1){if(Number.isNaN(e))throw new c(`Expected \`${t}\` to be a valid number${o?" or Infinity":""}, got NaN.`);if(!o&&!Number.isFinite(e))throw new c(`Expected \`${t}\` to be a finite number.`);if(e<r)throw new c(`Expected \`${t}\` to be \u{2265} ${r}.`)}class u extends m{name="AsyncRetryAbortError";cause;constructor(t){if(super("string"==typeof t?t:e(t,!1)??"Aborted"),"string"==typeof t){const e=new m(t);e.stack=this.stack,this.cause=e}else r(t)?(this.cause=t,this.message=t.message):this.cause=t}}async function w(e,r,i,n,m){if(e instanceof u)throw e.cause;if(e instanceof c&&!o(e)||t(e))throw e;const f=i.retries-(r-1),w={error:e,attemptNumber:r,retriesLeft:f};await i.onFailedAttempt(w),r>1&&await i.onRetry(e,r-1);const h=Date.now();if(h-n>=m||r>=i.retries+1||!await i.shouldRetry(w))throw e;let d=s((i.randomize?Math.random()+1:1)*i.minTimeout*i.factor**(r-1));d>i.maxTimeout&&(d=i.maxTimeout);const y=m-(h-n);if(y<=0)throw e;let b=d;d>y&&(b=y),b>0&&await a(b,i.signal,i.unref),i.signal?.throwIfAborted()}function h(t){throw new u(t??"Aborted")}async function d(t,e={}){e.signal?.throwIfAborted();const r={...e};r.retries??=10,r.forever??=!1,r.factor??=2,r.minTimeout??=1e3,r.maxTimeout??=1/0,r.randomize??=!0,r.onFailedAttempt??=i,r.onRetry??=i,r.shouldRetry??=n,r.forever&&(r.retries=1/0),f("retries",r.retries,0,!0),f("factor",r.factor,0,!1),f("minTimeout",r.minTimeout,0,!1),f("maxTimeout",r.maxTimeout,0,!0);const o=r.maxRetryTime??1/0;f("maxRetryTime",o,0,!0),r.minTimeout<1&&(r.minTimeout=1),r.factor<=0&&(r.factor=1);let a=0;const s=Date.now();for(;a<r.retries+1;){a++;try{r.signal?.throwIfAborted();const e=await t(h,a);return r.signal?.throwIfAborted(),e}catch(e){let t=e;"object"==typeof e&&e&&"bail"in e&&e.bail&&(t=new u(e)),await w(t,a,r,s,o)}}throw new m("Retry attempts exhausted without throwing an error.")}function y(t,e){return function(...r){return d(()=>t.apply(this,r),e)}}export{u as AsyncRetryAbortError,d as asyncRetry,y as makeRetriable};
@@ -0,0 +1,4 @@
1
+ declare function clamp(value: number, min: number, max: number): number;
2
+ declare function clamp(min: number, max: number): (value: number) => number;
3
+
4
+ export { clamp };
@@ -0,0 +1 @@
1
+ "use strict";exports.clamp=function(t,r,c){return void 0===c?c=>c<t?t:c>r?r:c:t<r?r:t>c?c:t};
@@ -0,0 +1 @@
1
+ function n(n,o,r){return void 0===r?r=>r<n?n:r>o?o:r:n<o?o:n>r?r:n}export{n as clamp};
@@ -0,0 +1,3 @@
1
+ declare function isObjectEmpty(obj: Record<string, unknown>): boolean;
2
+
3
+ export { isObjectEmpty };
@@ -0,0 +1 @@
1
+ "use strict";exports.isObjectEmpty=function(t){for(const r in t)if(Object.prototype.hasOwnProperty.call(t,r))return!1;return!0};
@@ -0,0 +1 @@
1
+ function t(t){for(const r in t)if(Object.prototype.hasOwnProperty.call(t,r))return!1;return!0}export{t as isObjectEmpty};
@@ -1 +1 @@
1
- "use strict";var e=require("../guard/index.js");const t=Uint8Array,r=ArrayBuffer,n=TextDecoder,o=new TextEncoder,c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=new Uint8Array(256);for(let e=0;e<c.length;e++)a[c.charCodeAt(e)]=e;const l={utf8:new n("utf8")};exports.base64ToUint8Array=function(e){const t=function(e){const t=e.replaceAll("-","+").replaceAll("_","/"),r=(4-t.length%4)%4;return t+"=".repeat(r)}(e),r=t.length;let n=.75*t.length,o,c=0,l,u,i,f;"="===t[t.length-1]&&(n--,"="===t[t.length-2]&&n--);const s=new Uint8Array(new ArrayBuffer(n));for(o=0;o<r;o+=4)l=a[t.charCodeAt(o)],u=a[t.charCodeAt(o+1)],i=a[t.charCodeAt(o+2)],f=a[t.charCodeAt(o+3)],s[c++]=l<<2|u>>4,s[c++]=(15&u)<<4|i>>2,s[c++]=(3&i)<<6|63&f;return s},exports.concatUint8Arrays=function(e,r){if(0===e.length)return new t(0);const n=new t(r??=e.reduce((e,t)=>e+t.length,0));let o=0;for(let t=0,r=e.length;t<r;t++){const r=e[t];n.set(r,o),o+=r.length}return n},exports.stringToUint8Array=function(e){return o.encode(e)},exports.toUint8Array=function(n){return n instanceof r?new t(n):r.isView(n)?new t(n.buffer,n.byteOffset,n.byteLength):void e.never(n,"value must be ArrayBuffer or ArrayBufferView")},exports.uint8ArrayToBase64=function(e,t=!1){let r="";const n=e.length;for(let t=0;t<n;t+=3)r+=c[e[t]>>2],r+=c[(3&e[t])<<4|e[t+1]>>4],r+=c[(15&e[t+1])<<2|e[t+2]>>6],r+=c[63&e[t+2]];return n%3==2?r=r.slice(0,Math.max(0,r.length-1))+"=":n%3==1&&(r=r.slice(0,Math.max(0,r.length-2))+"=="),t?r.replaceAll("+","-").replaceAll("/","_").replace(/=+$/,""):r},exports.uint8ArrayToString=function(e,t="utf8"){return l[t]??=new n(t),l[t].decode(e)};
1
+ "use strict";var e=require("../guard/index.js");const t=Uint8Array,r=ArrayBuffer,n=TextDecoder,o=new TextEncoder,c=/=+$/,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",l=new Uint8Array(256);for(let e=0;e<a.length;e++)l[a.charCodeAt(e)]=e;const u={utf8:new n("utf8")};exports.base64ToUint8Array=function(e){const t=function(e){const t=e.replaceAll("-","+").replaceAll("_","/"),r=(4-t.length%4)%4;return t+"=".repeat(r)}(e),r=t.length;let n=.75*t.length,o,c=0,a,u,i,f;"="===t[t.length-1]&&(n--,"="===t[t.length-2]&&n--);const s=new Uint8Array(new ArrayBuffer(n));for(o=0;o<r;o+=4)a=l[t.charCodeAt(o)],u=l[t.charCodeAt(o+1)],i=l[t.charCodeAt(o+2)],f=l[t.charCodeAt(o+3)],s[c++]=a<<2|u>>4,s[c++]=(15&u)<<4|i>>2,s[c++]=(3&i)<<6|63&f;return s},exports.concatUint8Arrays=function(e,r){if(0===e.length)return new t(0);const n=new t(r??=e.reduce((e,t)=>e+t.length,0));let o=0;for(let t=0,r=e.length;t<r;t++){const r=e[t];n.set(r,o),o+=r.length}return n},exports.stringToUint8Array=function(e){return o.encode(e)},exports.toUint8Array=function(n){return n instanceof r?new t(n):r.isView(n)?new t(n.buffer,n.byteOffset,n.byteLength):void e.never(n,"value must be ArrayBuffer or ArrayBufferView")},exports.uint8ArrayToBase64=function(e,t=!1){let r="";const n=e.length;for(let t=0;t<n;t+=3)r+=a[e[t]>>2],r+=a[(3&e[t])<<4|e[t+1]>>4],r+=a[(15&e[t+1])<<2|e[t+2]>>6],r+=a[63&e[t+2]];return n%3==2?r=r.slice(0,Math.max(0,r.length-1))+"=":n%3==1&&(r=r.slice(0,Math.max(0,r.length-2))+"=="),t?r.replaceAll("+","-").replaceAll("/","_").replace(c,""):r},exports.uint8ArrayToString=function(e,t="utf8"){return u[t]??=new n(t),u[t].decode(e)};
@@ -1 +1 @@
1
- import{never as e}from"../guard/index.mjs";const t=Uint8Array,r=ArrayBuffer,n=TextDecoder,o=new TextEncoder,c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",l=new Uint8Array(256);for(let e=0;e<c.length;e++)l[c.charCodeAt(e)]=e;function a(e){return o.encode(e)}const f={utf8:new n("utf8")};function u(e,t="utf8"){return f[t]??=new n(t),f[t].decode(e)}function i(e){const t=function(e){const t=e.replaceAll("-","+").replaceAll("_","/"),r=(4-t.length%4)%4;return t+"=".repeat(r)}(e),r=t.length;let n=.75*t.length,o,c=0,a,f,u,i;"="===t[t.length-1]&&(n--,"="===t[t.length-2]&&n--);const A=new Uint8Array(new ArrayBuffer(n));for(o=0;o<r;o+=4)a=l[t.charCodeAt(o)],f=l[t.charCodeAt(o+1)],u=l[t.charCodeAt(o+2)],i=l[t.charCodeAt(o+3)],A[c++]=a<<2|f>>4,A[c++]=(15&f)<<4|u>>2,A[c++]=(3&u)<<6|63&i;return A}function A(e,t=!1){let r="";const n=e.length;for(let t=0;t<n;t+=3)r+=c[e[t]>>2],r+=c[(3&e[t])<<4|e[t+1]>>4],r+=c[(15&e[t+1])<<2|e[t+2]>>6],r+=c[63&e[t+2]];return n%3==2?r=r.slice(0,Math.max(0,r.length-1))+"=":n%3==1&&(r=r.slice(0,Math.max(0,r.length-2))+"=="),t?r.replaceAll("+","-").replaceAll("/","_").replace(/=+$/,""):r}function h(e,r){if(0===e.length)return new t(0);const n=new t(r??=e.reduce((e,t)=>e+t.length,0));let o=0;for(let t=0,r=e.length;t<r;t++){const r=e[t];n.set(r,o),o+=r.length}return n}function s(n){return n instanceof r?new t(n):r.isView(n)?new t(n.buffer,n.byteOffset,n.byteLength):void e(n,"value must be ArrayBuffer or ArrayBufferView")}export{i as base64ToUint8Array,h as concatUint8Arrays,a as stringToUint8Array,s as toUint8Array,A as uint8ArrayToBase64,u as uint8ArrayToString};
1
+ import{never as e}from"../guard/index.mjs";const t=Uint8Array,r=ArrayBuffer,n=TextDecoder,o=new TextEncoder,c=/=+$/,l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=new Uint8Array(256);for(let e=0;e<l.length;e++)a[l.charCodeAt(e)]=e;function f(e){return o.encode(e)}const u={utf8:new n("utf8")};function i(e,t="utf8"){return u[t]??=new n(t),u[t].decode(e)}function A(e){const t=function(e){const t=e.replaceAll("-","+").replaceAll("_","/"),r=(4-t.length%4)%4;return t+"=".repeat(r)}(e),r=t.length;let n=.75*t.length,o,c=0,l,f,u,i;"="===t[t.length-1]&&(n--,"="===t[t.length-2]&&n--);const A=new Uint8Array(new ArrayBuffer(n));for(o=0;o<r;o+=4)l=a[t.charCodeAt(o)],f=a[t.charCodeAt(o+1)],u=a[t.charCodeAt(o+2)],i=a[t.charCodeAt(o+3)],A[c++]=l<<2|f>>4,A[c++]=(15&f)<<4|u>>2,A[c++]=(3&u)<<6|63&i;return A}function h(e,t=!1){let r="";const n=e.length;for(let t=0;t<n;t+=3)r+=l[e[t]>>2],r+=l[(3&e[t])<<4|e[t+1]>>4],r+=l[(15&e[t+1])<<2|e[t+2]>>6],r+=l[63&e[t+2]];return n%3==2?r=r.slice(0,Math.max(0,r.length-1))+"=":n%3==1&&(r=r.slice(0,Math.max(0,r.length-2))+"=="),t?r.replaceAll("+","-").replaceAll("/","_").replace(c,""):r}function s(e,r){if(0===e.length)return new t(0);const n=new t(r??=e.reduce((e,t)=>e+t.length,0));let o=0;for(let t=0,r=e.length;t<r;t++){const r=e[t];n.set(r,o),o+=r.length}return n}function g(n){return n instanceof r?new t(n):r.isView(n)?new t(n.buffer,n.byteOffset,n.byteLength):void e(n,"value must be ArrayBuffer or ArrayBufferView")}export{A as base64ToUint8Array,s as concatUint8Arrays,f as stringToUint8Array,g as toUint8Array,h as uint8ArrayToBase64,i as uint8ArrayToString};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "foxts",
3
- "version": "5.5.1",
3
+ "version": "5.7.0",
4
4
  "description": "Opinionated collection of common TypeScript utils by @SukkaW",
5
5
  "repository": {
6
6
  "url": "https://github.com/SukkaW/foxts"
@@ -94,6 +94,12 @@
94
94
  "require": "./dist/chunk/index.js",
95
95
  "default": "./dist/chunk/index.js"
96
96
  },
97
+ "./clamp": {
98
+ "types": "./dist/clamp/index.d.ts",
99
+ "import": "./dist/clamp/index.mjs",
100
+ "require": "./dist/clamp/index.js",
101
+ "default": "./dist/clamp/index.js"
102
+ },
97
103
  "./compare-source": {
98
104
  "types": "./dist/compare-source/index.d.ts",
99
105
  "import": "./dist/compare-source/index.mjs",
@@ -202,6 +208,12 @@
202
208
  "require": "./dist/is-network-error/index.js",
203
209
  "default": "./dist/is-network-error/index.js"
204
210
  },
211
+ "./is-object-empty": {
212
+ "types": "./dist/is-object-empty/index.d.ts",
213
+ "import": "./dist/is-object-empty/index.mjs",
214
+ "require": "./dist/is-object-empty/index.js",
215
+ "default": "./dist/is-object-empty/index.js"
216
+ },
205
217
  "./is-probably-ip": {
206
218
  "types": "./dist/is-probably-ip/index.d.ts",
207
219
  "import": "./dist/is-probably-ip/index.mjs",
@@ -338,43 +350,43 @@
338
350
  "author": "SukkaW <https://skk.moe>",
339
351
  "license": "MIT",
340
352
  "devDependencies": {
341
- "@eslint-sukka/node": "^8.10.4",
342
- "@happy-dom/global-registrator": "^20.10.2",
353
+ "@eslint-sukka/node": "^8.13.4",
354
+ "@happy-dom/global-registrator": "^20.10.6",
343
355
  "@istanbuljs/nyc-config-typescript": "^1.0.2",
344
356
  "@mitata/counters": "^0.0.8",
345
- "@monyone/aho-corasick": "^1.1.11",
357
+ "@monyone/aho-corasick": "^1.1.12",
346
358
  "@package-json/types": "^0.0.13",
347
359
  "@swc-node/register": "^1.11.1",
348
- "@swc/core": "^1.15.40",
360
+ "@swc/core": "^1.15.43",
349
361
  "@types/mocha": "^10.0.10",
350
- "@types/node": "^22.19.20",
362
+ "@types/node": "^22.20.1",
351
363
  "@types/sinon": "^21.0.1",
352
364
  "bumpp": "^10.4.1",
353
365
  "earl": "^2.0.0",
354
- "eslint": "^10.4.1",
355
- "eslint-config-sukka": "^8.10.4",
356
- "eslint-formatter-sukka": "^8.10.4",
366
+ "eslint": "^10.6.0",
367
+ "eslint-config-sukka": "^8.13.4",
368
+ "eslint-formatter-sukka": "^8.13.4",
357
369
  "fastscan": "^1.0.6",
358
- "happy-dom": "^20.10.2",
370
+ "happy-dom": "^20.10.6",
359
371
  "is-ci": "^4.1.0",
360
372
  "is-network-error": "^1.3.2",
361
373
  "mitata": "^1.0.34",
362
374
  "mocha": "^11.7.6",
363
375
  "modern-ahocorasick": "^2.0.4",
364
376
  "nyc": "^18.0.0",
365
- "rollup": "^4.61.1",
377
+ "rollup": "^4.62.2",
366
378
  "rollup-plugin-dts": "^6.4.1",
367
379
  "rollup-plugin-oxc-resolve": "^0.0.5",
368
380
  "rollup-plugin-swc3": "^0.12.1",
369
381
  "sinon": "^21.1.2",
370
- "ts-dedent": "^2.2.0",
382
+ "ts-dedent": "^2.3.0",
371
383
  "typescript": "^6.0.3",
372
384
  "word-list": "3.0.0"
373
385
  },
374
386
  "scripts": {
375
387
  "lint": "eslint --format=sukka .",
376
388
  "build-ts-xor": "SWC_NODE_IGNORE_DYNAMIC=1 node --require @swc-node/register ./src/ts-xor/_build.ts",
377
- "test": "SWC_NODE_IGNORE_DYNAMIC=1 SWC_NODE_INLINE_SOURCE_MAP=1 nyc mocha --require @swc-node/register --full-trace ./src/**/*.test.ts",
389
+ "test": "SWC_NODE_IGNORE_DYNAMIC=1 SWC_NODE_INLINE_SOURCE_MAP=1 nyc mocha --require @swc-node/register --full-trace 'src/**/*.test.ts'",
378
390
  "bench": "SWC_NODE_IGNORE_DYNAMIC=1 node --require @swc-node/register",
379
391
  "bench:all": "SWC_NODE_IGNORE_DYNAMIC=1 node --require @swc-node/register ./src/**/*.bench.ts",
380
392
  "build": "rollup -c rollup.config.ts --bundleConfigAsCjs --configPlugin swc3",