Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

schemaglobin

Package Overview
Dependencies
Maintainers
1
Versions
64
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

schemaglobin - npm Package Compare versions

Comparing version 3.0.0 to 3.1.0

2

dist/schemas/NumberSchema.d.ts

@@ -54,3 +54,5 @@ import { Schema, SchemaOptions, NullIfOptional } from "../types";

optional: NumberSchema<number, false>;
/** An number representing a valid Unix timestamp in milliseconds, e.g. as returned by `Date.now()` */
timestamp: NumberSchema<number, true>;
};
export {};

@@ -123,2 +123,4 @@ "use strict";

optional: new NumberSchema({ required: false }),
// Note: Timestamp is limited to four-digit years: 0000–9999
timestamp: new NumberSchema({ required: true, min: -62167219125000, max: 253370764800000 }),
});

2

package.json
{
"name": "schemaglobin",
"description": "Validate user-entered data.",
"version": "3.0.0",
"version": "3.1.0",
"repository": "https://github.com/dhoulb/schemaglobin",

@@ -6,0 +6,0 @@ "author": "Dave Houlbrooke <dave@shax.com>",

@@ -506,2 +506,3 @@ # Schemaglobin: Validate unknown user input against schemas

number.optional.validate(null);
number.timestamp.validate(Date.now());
phone.required.validate("+44123456789");

@@ -508,0 +509,0 @@ phone.optional.validate(null);

@@ -159,2 +159,4 @@ import { Schema, SchemaOptions, NullIfOptional } from "../types";

optional: NumberSchema<number, false>;
/** An number representing a valid Unix timestamp in milliseconds, e.g. as returned by `Date.now()` */
timestamp: NumberSchema<number, true>;
} = Object.assign(

@@ -166,3 +168,5 @@ <T extends number, R extends boolean = false>(options: NumberOptions<T, R> = {}): NumberSchema<T, R> =>

optional: new NumberSchema({ required: false }),
// Note: Timestamp is limited to four-digit years: 0000–9999
timestamp: new NumberSchema({ required: true, min: -62167219125000, max: 253370764800000 }),
},
);
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