New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

arktype

Package Overview
Dependencies
Maintainers
1
Versions
129
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

arktype - npm Package Compare versions

Comparing version 2.0.0-rc.25 to 2.0.0-rc.26

4

out/keywords/string/numeric.js
import { intrinsic, rootSchema } from "@ark/schema";
import { wellFormedNumberMatcher } from "@ark/util";
import { numericStringMatcher } from "@ark/util";
import { arkModule } from "../utils.js";
import { regexStringNode } from "./utils.js";
const root = regexStringNode(wellFormedNumberMatcher, "a well-formed numeric string");
const root = regexStringNode(numericStringMatcher, "a well-formed numeric string");
export const numeric = arkModule({

@@ -7,0 +7,0 @@ root,

@@ -44,3 +44,3 @@ import { $ark, writeUnboundableMessage } from "@ark/schema";

}
return (comparator === "==" ? ["minLength", "maxLength"]
return (comparator === "==" ? ["exactLength"]
: comparator[0] === ">" ? ["minLength"]

@@ -79,5 +79,6 @@ : ["maxLength"]);

const exclusive = comparator.length === 1;
// if the comparator is ==, both the min and max of that pair will be applied
for (const kind of getBoundKinds(comparator, typeof limit === "number" ? limit : limitToken, previousRoot, "right"))
s.constrainRoot(kind, { rule: limit, exclusive });
const boundKinds = getBoundKinds(comparator, typeof limit === "number" ? limit : limitToken, previousRoot, "right");
for (const kind of boundKinds) {
s.constrainRoot(kind, comparator === "==" ? { rule: limit } : { rule: limit, exclusive });
}
if (!s.branches.leftBound)

@@ -84,0 +85,0 @@ return;

{
"name": "arktype",
"description": "TypeScript's 1:1 validator, optimized from editor to runtime",
"version": "2.0.0-rc.25",
"version": "2.0.0-rc.26",
"license": "MIT",

@@ -37,4 +37,4 @@ "author": {

"dependencies": {
"@ark/util": "0.25.0",
"@ark/schema": "0.25.0"
"@ark/schema": "0.26.0",
"@ark/util": "0.26.0"
},

@@ -41,0 +41,0 @@ "publishConfig": {

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